-
-
Notifications
You must be signed in to change notification settings - Fork 674
Description
When we upgrade to RN v0.60.0 (that's #3548), we'll get this warning:
warn The following packages use deprecated "rnpm" config that will stop working from next release:
- react-native-orientation: https://github.com/yamill/react-native-orientation#readme
- rn-fetch-blob: https://npmjs.com/package/rn-fetch-blob
Please notify their maintainers about it. You can find more details at https://github.com/react-native-community/cli/blob/master/docs/configuration.md#migration-guide.
rn-fetch-blob
is easy to fix; we just have to upgrade to v0.11; I'm planning to do that in my PR for #3548.
react-native-orientation
is unmaintained, though. The fix for this warning is very simple, but the PR for it has gathered dust, and the repo isn't getting updates.
This will take some assembly in native code, which should all be spelled out in the replacement library's installation instructions.
I recommend trying Expo's ScreenOrientation; Expo libraries are generally frequently maintained, and we can newly use them since #4016 landed. If we're going with that, we'll follow the instructions for a "bare React Native app" (ours isn't "managed" by Expo), and use yarn add expo-screen-orientation
instead of npm install
. Since Expo uses TypeScript instead of Flow, we'll have to put together a libdef, unless FlowTyped has one (I don't think it does). We have a new doc for that, and it would be nice for that to be updated with anything new we learn along the way.