React-native-router-flux: Actions.replace: There is no route defined for Key X

Created on 12 Sep 2018  ·  5Comments  ·  Source: aksonov/react-native-router-flux

Version

Tell us which versions you are using:

  • react-native-router-flux v4.0.1
  • react v16.3.1
  • react-native v0.55.4
const scenes = Actions.create(
            <Lightbox>
                <Scene key="root">
                    <Scene hideNavBar activeTintColor={AppColors.primary} key="main" tabBarPosition={'bottom'}
                           tabs={true}>
                        <Scene hideNavBar key="index" title="首页" icon={TabIcon('\ue62f')} component={index}/>
                        <Scene hideNavBar key="category" title="商品分类" icon={TabIcon('\ue634')} component={category}/>
                        <Scene hideNavBar key="cart" title="购物车" icon={observer(TabIcon('\ue63f', 'cart'))}
                               component={cart}/>
                        <Scene hideNavBar key="user" title="我的" icon={TabIcon('\ue6e6')} component={User}/>
                    </Scene>

                </Scene>
            </Lightbox>);

Steps to reproduce

1.yarn add aksonov/react-native-router-flux
2.in page 'index' when using Actions.replace("cart") get error : There is no route defined for key undefined Must be one of :'index','category','test','cart','user'

bug

Most helpful comment

I am working in a fix for it.

All 5 comments

I'll check it - sounds like something it was already fixed for the next release.

Is there any solution for now to naviagte between tabs with props?

I am working in a fix for it.

Could you check last published version 4.0.2 to see if that might have fixed your problem?

On 25 Sep 2018, at 04:05, 默 notifications@github.com wrote:
running well in my project, great

Great. Closing this one.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

willmcclellan picture willmcclellan  ·  3Comments

moaxaca picture moaxaca  ·  3Comments

sreejithr picture sreejithr  ·  3Comments

maphongba008 picture maphongba008  ·  3Comments

basdvries picture basdvries  ·  3Comments