jeremybarbet / react-native-modalize

A highly customizable modal/bottom sheet that loves scrolling content.
https://jeremybarbet.github.io/react-native-modalize
MIT License
2.82k stars 299 forks source link

Error: Warning: This synthetic event is reused for performance reasons #500

Open joseph-ampfer opened 6 months ago

joseph-ampfer commented 6 months ago

Describe the bug Every time I try to use Modalize I get the synthetic event warning and Possible unhandled promise rejection: TypeError: Cannot read property 'layout' of null.

Even with the bare minimum modal, with only one line of text in it.

const modalizeRef = useRef(null);

const onOpen = () => { modalizeRef.current?.open(); }

<Pressable onPress={onOpen}> <Text style={twtext-white ml-21}>open modalize</Text> </Pressable>

` <Modalize ref={modalizeRef}

Test test

`

Dependencies:

gyaurb commented 5 months ago

You need to add this as props:

avoidKeyboardLikeIOS={true} keyboardAvoidingBehavior={Platform.OS === 'ios' ? undefined : 'height'