Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
iOS and Android apps with React Native - React Native Navigation stack example
import { Navigation } from 'react-native-navigation';
import Login from './screens/Login';
import Dashboard from './screens/Dashboard';
import Settings from './screens/Settings';
import Posts from './screens/Posts';
import TopBar from './components/TopBar';
export default function registerScreens(store, Provider) {
Navigation.registerComponent('MyApp.Login', () => Login, store, Provider);
Navigation.registerComponent('MyApp.Dashboard', () => Dashboard, store, Provider);
Navigation.registerComponent('MyApp.Settings', () => Settings, store, Provider);
Navigation.registerComponent('MyApp.Posts', () => Posts, store, Provider);
Navigation.registerComponent('MyApp.TopBar', () => TopBar, store, Provider);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment