undefined is not a function (evaluating 'babelHelpers.asyncToGenerator') react-native

℡╲_俬逩灬. 提交于 2019-12-14 03:29:09

问题


I've got this error and get stuck.

I tried to remove .babelrc file but this doesn't make it work.


回答1:


You need to import babel-polyfill as a first thing in your script:

import 'babel-polyfill';



回答2:


I had this exact same issue, but I fixed it by adding transform-async-to-generator to my .babelrc file from this babel package babel-plugin-transform-async-to-generator



来源:https://stackoverflow.com/questions/44237944/undefined-is-not-a-function-evaluating-babelhelpers-asynctogenerator-react-n

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!