?check that one ⠀⠀⠀⠀ ? React Native Navigation + MobX Boilerplate ?
kanzitelli/react-native-navigation-starter is using React Native Navigation v3 with MobX-State-Tree and Redux (pick one) and more goodies inside. So this is your case, then check it out ?
A simple boilerplate based on MobX (w/ Provider) instead of Redux and wix/react-native-navigation.
.push({...})
s for the first tab through MobX: Stores.App.rootNavigator.push({...})
. You can change .rootNavigator
in any component. (based on this issue)Account
store), the app opens a modal with text inputs.MobX Provider
. Now all components can use @inject('App', 'Counter', ...)
for accessing stores through const { App, Counter } = this.props;
. (based on this comment).react '16.0.0-alpha.12'
react-native '0.46.1'
react-native-navigation '1.1.134'
mobx '^3.1.15'
mobx-persist '^0.3.3'
mobx-react '^4.2.1'
flow-bin '^0.47.0'
git clone https://github.com/kanzitelli/react-native-navigation-mobx-boilerplate.git
cd react-native-navigation-mobx-boilerplate && yarn install
. Make sure yarn
is installed on your machine.react-native run-ios
or react-native run-android
(if you have any errors while building the project for iOS, remove the ios/build
directory or visit facebook/react-native/issues/7308 for more information).Thanks to @megahertz for sharing the gist that shows how to create a mobx Provider which can be used with RNN.