Implimenting Router into React Native with Redux
If you’re like me, shifting from React.js to React Native might’ve had you asking, “So, where’s my beloved React Router?” You’re not alone! As of May 2016, React Router and React Native are still playing hard-to-get with each other.
But, who doesn’t love a challenge, right? It’s time for us to roll up our sleeves and get a little creative. I’ve found a way to bring the charm of React Router into our React Native projects, and it involves our good old friend: Redux.
Redux, our trusty state-management Swiss Army knife, is going to help us cook up our very own navigation history store. It’s going to be like a diary of the app adventure, marking down every screen we wander into. This nifty trick lets us do some pretty cool things like navigating on a whim, mimicking the ‘back’ and ‘forward’ buttons, and even more.
find my work here : https://github.com/barockok/routive
Just keep in mind, this is a trail we’re blazing ourselves. React Router doesn’t officially support React Native yet, and we’re navigating uncharted waters here. So, be sure to always keep an eye on the official docs for any updates.