This repository was archived by the owner on Aug 19, 2022. It is now read-only.
This repository was archived by the owner on Aug 19, 2022. It is now read-only.
Radium incompatible with React ref forwarding #1010
Closed
Description
Any component which uses React ref forwarding fails to render when wrapped in the Radium higher order component.
I have created a minimal reproduction of this issue.
Relevant code from repro:
// This works
const TestRadium = Radium(props => <div>Radium works</div>);
// This works
const TestForwardRefs = React.forwardRef((props, ref) => (
<div ref={ref}>Forward refs work</div>
));
// This does not render
const TestBoth = Radium(TestForwardRefs);