react-native-modalfy
react-native-modalfy copied to clipboard
fix: remove "useInsertionEffect must not schedule updates" warning when closing a modal
This change removes this warning that appears:
Warning: useInsertionEffect must not schedule updates
We upgraded a project to RN 0.79.2 and this warning started appearing when closing a modal. I found that if transitionOptions is not present the warning will not appear. When transitionOptions is present on createModalStack this warning will appear.
It's possible that this started showing up in RN 0.78 when they made the change to react 19.
Something must have changed internally in react 19 and/or react native.