我一直在尝试更改堆栈导航器标题的高度。但是,没有任何效果!
<Stack.Navigator initialRouteName="LiveLandingScreen">
<Stack.Screen name="LiveLandingScreen" component={LiveLandingScreen} />
<Stack.Screen name="History" component={History} />
</Stack.Navigator>
代码工作正常,但是有人可以帮助我更改标题高度吗?
谢谢
您需要执行此操作,如果我们假设要更改“历史记录”标题栏的高度,则可以执行以下操作:
<Stack.Navigator initialRouteName="LiveLandingScreen">
<Stack.Screen name="LiveLandingScreen" component={LiveLandingScreen} />
<Stack.Screen name="History" component={History} option={{headerStyle: {height: 60}}} />. ///ADD OPTION
</Stack.Navigator>
希望对您有帮助<3
本文收集自互联网,转载请注明来源。
如有侵权,请联系[email protected] 删除。
我来说两句