按照
http://bbs.reactnative.cn/topic/10/%E5%9C%A8windows%E4%B8%8B%E6%90%AD%E5%BB%BAreact-native-android%E5%BC%80%E5%8F%91%E7%8E%AF%E5%A2%83/2配置的,在执行:
react-native start 后,打开网址:
http://localhost:8081/index.android.bundle?platform=android ,会遇到
{
-
message: "TransformError: C:\Users\Administrator\MyProject\node_modules\react-deep-force-update\lib\index.js: [BABEL] C:\Users\Administrator\MyProject\node_modules\react-deep-force-update\lib\index.js: Unknown option: C:\Users\Administrator\MyProject\node_modules\react-deep-force-update\.babelrc.stage",
-
type: "TransformError",
-
errors: [
-
{ }
-
的错误
解决方法:
1、找到你创建的项目,进入
位置
\node_modules\babel\test里面,将.babelrc文件删除掉,重新编译。
成功页面: