React-native-router-flux: TypeError: undefined is not a function this._children[typeof Symbol === 'function'? Symbol.iterator: '@@iterator']()')

Created on 18 Oct 2017  路  8Comments  路  Source: aksonov/react-native-router-flux

Version

Tell us which versions you are using:

  • react-native-router-flux v4.0.0-beta.22 (v3 is not supported)
  • react-native v0.49.3

Expected behaviour

Router don't crash

Actual behaviour

Router crash on android when navigating between screens, with error:

TypeError: undefined is not a function this._children[typeof Symbol === 'function'? Symbol.iterator: '@@iterator']()')

It is maybe linked to this:
https://github.com/react-community/react-navigation/issues/1777

Steps to reproduce

For non-obvious bugs, please fork this component, modify Example project to reproduce your issue and include link here.

  1. Just run any app with StackNavigator and babelrc es2015 and stage-0 presets
    2.
    3.

Most helpful comment

npm install --save babel-polyfill

and add

import "babel-polyfill"

to your entry file.

This work for me on Android.

All 8 comments

Tested a little bit more options, it really seems to be a bug inherent to the stack navigator. The tab navigator is working well...

Same here

@CarbonC I solved my problem by importing babel-polyfill, can you try this?

Yeah, i just updated the babel-react-native-preset version right now and it fixed it. Thanks!

@CarbonC Hi, I just started trying out React and having trouble with Navigation.

I got TabNavigator working, but not StackNavigator.

Can you please state which version of babel-react-native-preset you updated to fix the issue?

For reference these are my versions:

{ "name": "SimpleApp", "version": "0.0.1", "private": true, "scripts": { "start": "node node_modules/react-native/local-cli/cli.js start", "test": "jest" }, "dependencies": { "react": "16.0.0-beta.5", "react-native": "0.49.5", "react-navigation": "^1.0.0-beta.16" }, "devDependencies": { "babel-jest": "21.2.0", "babel-preset-react-native": "4.0.0", "jest": "21.2.1", "react-test-renderer": "16.0.0-beta.5" }, "jest": { "preset": "react-native" } }

Thanks

@sfreeman28 - your error is probably related to this issue.

@skicson Yea thanks I just saw that Issue report and looks like what I am getting. Thanks for the help

npm install --save babel-polyfill

and add

import "babel-polyfill"

to your entry file.

This work for me on Android.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

YouYII picture YouYII  路  3Comments

fgrs picture fgrs  路  3Comments

tonypeng picture tonypeng  路  3Comments

GCour picture GCour  路  3Comments

booboothefool picture booboothefool  路  3Comments