diff --git a/packages/rn-tester/NativeComponentExample/js/MyNativeView.js b/packages/rn-tester/NativeComponentExample/js/MyNativeView.js index 5d992c04f4fd..d9d166abeba1 100644 --- a/packages/rn-tester/NativeComponentExample/js/MyNativeView.js +++ b/packages/rn-tester/NativeComponentExample/js/MyNativeView.js @@ -88,7 +88,7 @@ function getTextFor(measureStruct: MeasureStruct): string { // This is an example component that migrates to use the new architecture. export default function MyNativeView(props: {}): React.Node { - const containerRef = useRef(null); + const containerRef = useRef | null>(null); const ref = useRef | null>(null); const legacyRef = useRef | null>(null); const [opacity, setOpacity] = useState(1.0);