React native 为什么类组件中的本机导航速度非常慢

React native 为什么类组件中的本机导航速度非常慢,react-native,react-native-android,react-navigation,react-native-navigation,react-navigation-drawer,React Native,React Native Android,React Navigation,React Native Navigation,React Navigation Drawer,如果我使用类组件链接我的导航,它将花费大约40秒的时间才能切换到屏幕。 为什么请? class NotificationScreen extends Component { render() { return ( <ApplicationProvider mapping={mapping} theme={theme}> <View style={{ flex: 1, alignItems: 'center', justifyContent

如果我使用类组件链接我的导航,它将花费大约40秒的时间才能切换到屏幕。 为什么请?

class NotificationScreen extends Component {
render() {
    return (
        <ApplicationProvider mapping={mapping} theme={theme}>
        <View style={{ flex: 1, alignItems: 'center', justifyContent: 'center' }}>
         <Button onPress={() => this.props.navigation.goBack()} title="Go back home">Go back</Button>
       </View>
     </ApplicationProvider>
    );
}
}
export default NotificationScreen;
类通知屏幕扩展组件{
render(){
返回(
this.props.navigation.goBack()}title=“回家”>返回
);
}
}
导出默认通知屏幕;
下面是导航

const Drawer = createDrawerNavigator();

   class App extends Component {
 render(){
 return (
<>
{!AsyncStorage.getItem('@MySuperStore:key')?
<ApplicationProvider mapping={mapping} theme={theme}>
<NavigationContainer>
  <Drawer.Navigator drawerType="slide" initialRouteName="Home">
    <Drawer.Screen name="Home" component={Dashboard}  />
    <Drawer.Screen name="Notifications" component= 
  {NotificationScreen} />
  </Drawer.Navigator>
  </NavigationContainer>

 </ApplicationProvider>
 :
  <AppNavigatorLanding />
const Drawer=createDrawerNavigator();
类应用程序扩展组件{
render(){
返回(
{!AsyncStorage.getItem('@MySuperStore:key')?
:
}


谁曾经经历过这种情况?

如果您提供零食项目,查看问题会更有帮助。请参阅:

如果您提供零食项目,查看问题会更有帮助。请参阅: