通过Transpiling gulp-babel
服务器和browserify
与babelify
客户端-使用异步和我的代码等待.这些功能似乎转变得很好,但......
Error: Cannot find module 'babel-runtime/helpers/typeof'
的内容 .babelrc
{ "presets": ["react", "es2015"], "plugins": [ "transform-class-properties", "transform-async-to-generator", "transform-runtime" ] }
相关内容 package.json
"babel-core": "6.3.13", "babel-eslint": "4.1.6", "babel-plugin-transform-async-to-generator": "6.3.13", "babel-plugin-transform-class-properties": "6.3.13", "babel-plugin-transform-runtime": "6.3.13", "babel-preset-es2015": "6.3.13", "babel-preset-react": "6.3.13", "babelify": "7.2.0", "browserify": "12.0.1", "gulp-babel": "6.1.0",
我已经找到了一些其他的提及,其中许多似乎在这里引领 - https://github.com/babel/babel/issues/2954
但是我在上面的链接上获得了404,实际上看不到任何与之相关的问题babel
- https://github.com/babel/babel/issues重定向到https://github.com/babel/babel/pulls
有任何想法吗?
事实证明我需要安装babel-runtime
,我认为随着Babel v6的发布而被弃用.