jamesknelson / starter-kit

Project boilerplate using React, Redux and Uniloc
http://unicornstandard.com/packages/boilerplate.html
462 stars 42 forks source link

SyntaxError: Unexpected token import #9

Closed neural9 closed 8 years ago

neural9 commented 8 years ago

Running into this when downloaded. I've installed everythingI can think of with regards to babel but I've just hit a wall with my knowledge.

I'm on node 5.5.0, npm 3.6.0.

gulp serve

[09:33:16] Requiring external module babel-core/register /Users/re/Documents/Coding/test/gulpfile.babel.js:1 (function (exports, require, module, filename, dirname) { import del from "del"; ^^^^^^

SyntaxError: Unexpected token import at exports.runInThisContext (vm.js:53:16) at Module._compile (module.js:387:25) at loader (/Users/re/Documents/Coding/test/node_modules/babel-register/lib/node.js:128:5) at Object.require.extensions.(anonymous function) as .js at Module.load (module.js:357:32) at Function.Module._load (module.js:314:12) at Module.require (module.js:367:17) at require (internal/module.js:16:19) at Liftoff.handleArguments

neural9 commented 8 years ago

this needs to be added to package.json

"babel": { "presets": ["es2015"] },