我正在使用dependencyOverrides += "org.scala-lang.modules" % "scala-xml_2.12" % "1.0.6"
依赖项创建页面导航,如下例所示:
react-navigation
我想创建一个全局const MainNavigator = createStackNavigator({
Home: { screen: HomeScreen },
Profile: { screen: ProfileScreen }
});
const App = createAppContainer(MainNavigator);
,但仍始终显示在View
和HomeScreen
页面上。
答案 0 :(得分:0)
const MainNavigator = createStackNavigator({
Home: { screen: HomeScreen },
Profile: { screen: ProfileScreen }
});
class MainNavigatorWithCustomView extends React.Component {
static router = MainNavigator.router;
render() {
return (
<View style={{flex: 1}}>
<MainNavigator {...this.props} />
{/* render some absolute positioned thing on top here */}
</View>
);
}
}