Actions.replace: There is no route defined for Key X
See original GitHub issueVersion
Tell us which versions you are using:
](url)- 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’
Issue Analytics
- State:
- Created 5 years ago
- Comments:5
Top Results From Across the Web
React Native: There is no route defined for key X Must be one ...
I'm trying to make it so that whenever users click the B tab, the B stack resets, so the user is always served...
Read more >NavigationActions reference - React Navigation
The Replace action replaces the route at the given key with another route. key - _string - required - Key of the route...
Read more >Rails Routing from the Outside In - Ruby on Rails Guides
How to declare route parameters, which are passed onto controller actions. ... Change :username in the route definition if you do not want...
Read more >How React Hooks can replace React Router - LogRocket Blog
Read more to find out how React Hooks can replace React Router. ... In the routes object, you define your routes as keys...
Read more >Working with routes for HTTP APIs - Amazon API Gateway
You can define specific HTTP methods for your route. ... If there's no $default stage, then the API returns {"message":"Not Found"} .
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I am working in a fix for it.
Great. Closing this one.