-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adopt RNRF for latest React Navigation (v2+) #3068
Comments
I have this partially done - when finished I can push a PR and reference it here. |
I want to know what version of react-native is required after the upgrade? |
@gyf19 I'll confirm it as soon as I get back to contribute here - probably end of next week. Thank you. |
I'm really looking forward to an integration with the new versions since the following bug is very visible in our app: react-navigation/react-navigation#4185 It's fixed in 2.5.5 :) |
Unfortunately it seems to be quite hard... I started and stuck here: react-navigation/react-navigation#4481 As you can see react-navigation starts recommending to store state within their library only and will not support (?) external management of state with Redux, MobX, etc. (as well as RNRF), etc. starting next major version. I will think what I can do. |
I found one easy and one complex way. First is to remove state management from RNRF, second is to build own navigators and use them instead of react-navigation ones, use only views from react-navigation. I'm working on first way while probably second way may be implemented at the future (or maybe not). Feel free to check my PR (Some links work, some not - login/lightbox/modal don't work yet) |
@daviscabral what do you think about my comments above and my PR? There are still a lot of things to to do, maybe you can help here (new tab navigator, our custom actions like popTo, etc).... |
@aksonov Great - I've been thinking about removing state management from RNRF - but that would make the project name a bit out of sync with it. I'll check your PR and start to hack on missing stuff - let me know things that you would prefer me to look into first. |
@daviscabral Could you clarify - "make the project name a bit out of sync with it." ? RNRF name? |
@aksonov sure - yeah - when I was trying to make it to work with I have created a few helpers/utils for some projects where I am using |
@daviscabral Great! Also we can remove mobx now too to make RNRF more lightweight (everybody who are observing state/or currentScene will be able to pass own onNavigationState function) |
@aksonov I can do it - even provide the way to connect it with Also - with the new React context API - we might want to explore that instead of a |
* react-navigation-v2: use WIP RNRF for Example revert RN to 0.55.4 upgrade Example to RN0.56 WIP: migration to react-navigation v2.x (aksonov#3068)
…e-action * react-navigation-v2: small tweaks bump version introduce onStateChange handler to be used instead of createReducer fix navTransparent add onEnter/onExit handlers and automatic transitions fix eslint fix error more eslint fixes fix eslint errors fix error fix eslint fix custom navigators Babel v7, ESlint fixes, React/React Navigation upgrades, mobx removed (aksonov#3142) use WIP RNRF for Example revert RN to 0.55.4 upgrade Example to RN0.56 WIP: migration to react-navigation v2.x (aksonov#3068)
Please check latest 4.0.0-beta.40, it uses React Navigation v2.x now |
There's quite the annoying bug in 2.x of RNavigation, did anyone find a workaround? react-navigation/react-navigation#4884 Unfortunately, I'm still stuck in the beta's because of it... |
Current 4.0.0-beta.31 depends from react-navigation 1.5.6. It would be great to migrate to latest v2.
createNavigator
API is changed and some other breaking changes were made..The text was updated successfully, but these errors were encountered: