未显示 React-native Tab-navigator

React-native Tab-navigator not displayed

我想在我的 app.For 中显示一个我正在使用 this 的 TabNavigator,但现在我不得不重组我的代码,它不再工作了。 这是我的代码:

主要 class :

import React, {Component} from 'react';
import {View,Text, WebView,StyleSheet} from 'react-native';
import { TabNavigator } from "react-navigation";
const Navigation = TabNavigator({
  Prod: { screen: Prod },
  ContinuousDeployment: { screen: ContinuousDeployment },
});
export default class Mattermost extends Component{
    constructor(props){
        super(props);

        this.state = ({
            MMAUTHTOKEN : null,
            BASICAUTH : null,
        });
    }
    render(){
        if(this.state.MMAUTHTOKEN === undefined || this.state.MMAUTHTOKEN === null){
            return(
                /*Another page , not the tab*/
            );
        }
        else if(this.state.BASICAUTH === undefined || this.state.BASICAUTH === null){
                return(
                    /*Another page , not the tab*/
                );
        }
        else{
            return <View>{Navigation}</View>;
        }
    }

这是我其中一个页面的 class:

import React,{Component} from 'react';
import {View,Text,StyleSheet} from 'react-native';


export default class Prod extends Component{
    constructor(props){
        super(props);
    }

    static navigationOptions = {
        tabBarLabel: 'Prod',
        tabBarIcon: ({ tintColor }) => (
            <Image source={require('../Images/Icones/jenkins.png')} style={[styles.icon, {tintColor: tintColor}]}/>
        ),
    };

    put(){
    }
    render(){
        return (
            <View>
                <Text>Prod</Text>
            </View>
        );
    }
}
const styles = StyleSheet.create({
  icon: {
    width: 26,
    height: 26,
  },
});

它之前运行良好,但现在它显示白屏,没有标签,并且没有任何警告或错误。如果有人可以帮助我,那将非常酷!提前致谢,亚历克斯

改变这个

return <View>{Navigation}</View>;

return <View><Navigation /></View>;

return <Navigation />;

应该可以解决这个问题。