/**
* Created by YiBing on 2017/5/5.
*
* 一个StackNavigator详细的例子,效果:1个主页面,2个子页面,每个页面有三个按钮,可以跳转到相应的页面。
*
* React Navigation -- StackNavigator:
API Definition--StackNavigator(RouteConfigs, StackNavigatorConfig);
RouteConfigs--StackNavigator({
// For each screen that you can navigate to, create a new entry like this:
Profile: {
// `ProfileScreen` is a React component that will be the main content of the
screen.
screen: ProfileScreen,
// When `ProfileScreen` is loaded by the StackNavigator, it will be given a
`navigation` prop.
// Optional: When deep linking or using react-navigation in a web app, this path is
used:
path: 'people/:username',
// The action and route params are extracted from the path.
// Optional: Override the `navigationOptions` for the screen
navigationOptions: ({navigation}) => ({
title: `${navigat
React Navigation--Stack Navigator 详细的例子
最新推荐文章于 2024-05-23 09:59:39 发布