running "gulp" not working after installing babel 6
See original GitHub issueI pulled the latest este, ran npm install
and then gulp
. Running the gulp default task results in:
$ gulp
[11:25:20] Requiring external module babel/register
/Users/rkoberg/Sites/este/node_modules/babel/node_modules/babel-core/lib/transformation/file/options/option-manager.js:126
if (!option) this.log.error("Unknown option: " + alias + "." + key, ReferenceError);
^
TypeError: Cannot read property 'error' of undefined
at OptionManager.mergeOptions (/Users/rkoberg/Sites/este/node_modules/babel/node_modules/babel-core/lib/transformation/file/options/option-manager.js:126:28)
at OptionManager.addConfig (/Users/rkoberg/Sites/este/node_modules/babel/node_modules/babel-core/lib/transformation/file/options/option-manager.js:107:10)
at OptionManager.findConfigs (/Users/rkoberg/Sites/este/node_modules/babel/node_modules/babel-core/lib/transformation/file/options/option-manager.js:168:35)
at OptionManager.init (/Users/rkoberg/Sites/este/node_modules/babel/node_modules/babel-core/lib/transformation/file/options/option-manager.js:229:12)
at compile (/Users/rkoberg/Sites/este/node_modules/babel/node_modules/babel-core/lib/api/register/node.js:117:22)
at normalLoader (/Users/rkoberg/Sites/este/node_modules/babel/node_modules/babel-core/lib/api/register/node.js:199:14)
at Object.require.extensions.(anonymous function) [as .js] (/Users/rkoberg/Sites/este/node_modules/babel/node_modules/babel-core/lib/api/register/node.js:216:7)
at Module.load (module.js:356:32)
at Function.Module._load (module.js:311:12)
at Module.require (module.js:366:17)
googling for “babel-core/lib/transformation/file/options/option-manager.js:126 TypeError: Cannot read property ‘error’ of undefined” brings up a page of similar complaints about switching to babel 6. The most common problem seems to be that a cached version of babel is being used. The only thing I have global is npm. I cleared my user’s npm cache and ran the npm install again, but still get the error above. Any ideas how to fix?
Issue Analytics
- State:
- Created 8 years ago
- Comments:13 (13 by maintainers)
Top Results From Across the Web
How to fix "cannot find module 'gulp-babel'"? - Stack Overflow
1. Type npm install gulp-babel@8.0.0 from the project directory. – Hardik Shah. Jul 29, 2019 at 11:46 · It helped! Thank you! But...
Read more >Working with BabelJS and Gulp - Tutorialspoint
In this chapter, we will create project setup using babel and gulp. Gulp is a task runner that uses Node.js as a platform....
Read more >Teaching Gulp ES6, with Babel 6 - James K Nelson
Babel 6 doesn't play well with its younger self, so start by removing any older Babel packages from package.json — babel , babel-core...
Read more >gulp-babel - npm
Start using gulp-babel in your project by running `npm i gulp-babel`. There are 1967 other projects in the npm registry using gulp-babel.
Read more >babel/node - Babel.js
You should not be using babel-node in production. It is unnecessarily heavy, with high memory usage due to the cache being stored in...
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
Cache clean then reinstall gulp glboally I guess. I don’t know. I switched to Node 5 and everything worked for me.
I think I know where is the problem. https://github.com/este/este/blob/e65b3a85551d8ed77dc9055ef0460ffce330bc82/.babelrc#L7
React Native 0.20 should allow me to fix it.