react-native-keyboard-aware-scroll-view
react-native-keyboard-aware-scroll-view copied to clipboard
Fix crash on `shouldCallGetNode` in tests
In our test suite (jest + react-native-testing-library) Platform.constants
is an empty object. This was making the previous !Platform.constants
check pass, but caused a crash when trying to access major
on reactNativeVersion
.
This fix correctly checks if reactNativeVersion
is present and is an object to avoid this issue.
This is a legitimate issue breaking all test suites on the latest versions of React Native. Could any contributor in this project please approve this PR ?
Can second this is a huge issue for me too and this fixes it for me.