title: how can I hide some tabs on react native tab view?
body: <p>I used tab view react native on my app and I want to hide some tabs by changing settings but I don't know how can I do that.
  For now, I have 3 tabs: personal, company and material, in settings I can check the tabs, for example when company is not checked should not appears on tab view</p>
  
  <pre><code>constructor(props) {
      super(props);
      this.state = {
        index: 0,
        routes: [
          { key: 'personal', title: 'personal' },
          { key: 'company', title: 'company' },
          { key: 'material', title: 'material' }
        ],
      };
    }
  _renderTabBar = props =&gt; {
      return (
        &lt;View&gt;
          &lt;TabBar
            {...props}
            indicatorStyle={{backgroundColor: 'white'}}
            renderIcon={
              props =&gt; this._getTabBarIcon(props)
            }
            onTabPress={ tab =&gt; this.changeTabs(tab)}
            style={{backgroundColor: "#5243af"}}
            tabStyle={styles.tabStyle}
            labelStyle={{fontSize: Fonts.moderateScale(15), marginBottom: 10}}
            contentContainerStyle={{height: Metrics.HEIGHT * 0.1, elevation: 0}}
          /&gt;
        &lt;/View&gt;
      );
    };
  &lt;TabView style={{ backgroundColor: 'white'}}
                  navigationState={this.state}
                  renderTabBar={ this._renderTabBar}
                  onIndexChange={index =&gt; this.setState({ index })}
                  initialLayout={{ width: Dimensions.get('window').width}}
                  renderScene={this._renderScene} /&gt;
  </code></pre>