Skip to content

Losing Actions in Tabbar #1231

Closed
Closed
@rrikesh

Description

@rrikesh

Version

  • react-native-router-flux v3.32.0
  • react-native v0.33.1

Issue:

I'm having issues implementing Tabbar on a non-main page. The API Configuration talks about using a schema but I'm confused how to do it.

My current setup:

I have a main page where I define the routes to be used, something like:

<Router>
     <Scene key="root" hideNavBar="true">
          <Scene key="Scene1" component={Scene1} title="Scene1Title" initial={somecondition} />
          <Scene key="Scene2" hideNavBar={false} component={Scene2} title="Scene2Title" />
          <Scene key="Scene3" hideNavBar={false} component={Scene3} title="Scene3Title" />
     </Scene>
</Router>

This works perfectly well. Now, on Scene3, I added another Router component to build the Tabbar:

return (

      <Router>
        <Scene
          key="tabbar"
          tabs={true}
          tabBarStyle={styles.tabBarStyleAndroid}
        >
          <Scene key="tab1" title="tab1title" icon={someIcon} >
            <Scene key="tab1a"
              component={Tab1a}
              title="Tab1a title"
            />
          </Scene>
          <Scene key="tab2" title="tab2title" icon={someIcon}>
            <Scene key="tab2a"
              component={Tab2a}
              title="Tab2a title"
            />
          </Scene>
        </Scene>
    </Router>
      );

Here again, when I visit Scene3, I get a Tabbar without issues, however, if I'm in a tab and want to go back to the scenes previously defined, I get an error:

[react-native-router-flux] missed route data for key=Scene1

How can I get this to work properly?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions