Since it is called es6 and I am using es6 syntax why are let and others are not supported?
See original GitHub issueHi!
The project seems promising however I cannot make it work on my ES6 code. I also added ‘use strict’; and using ESlint.
SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode
at exports.runInThisContext (vm.js:53:16)
at Module._compile (module.js:373:25)
at Object.Module._extensions..js (module.js:416:10)
at Module.load (module.js:343:32)
at Function.Module._load (module.js:300:12)
at Module.require (module.js:353:17)
at require (internal/module.js:12:17)
at Object.<anonymous> (..emitted..\plato.js:30:15)
at Module._compile (module.js:409:26)
at Object.Module._extensions..js (module.js:416:10)
My npm is:
npm: '2.15.9',
ares: '1.10.1-DEV',
http_parser: '2.7.0',
icu: '56.1',
modules: '46',
node: '4.6.1',
openssl: '1.0.2j',
uv: '1.9.1',
v8: '4.5.103.37',
zlib: '1.2.8'
***Update: updated to node: ‘7.1.0’, now all I get is NaN everywhere and having issues with .reduce()
Error reading file src\client\application.js: TypeError: (options.globals || []).reduce is not a function
TypeError: (options.globals || []).reduce is not a function
at new Config (\node_modules\eslint\lib\config.js:211:44)
at CLIEngine.executeOnText (\node_modules\eslint\lib\cli-engine.js:741:28)
at lint (\node_modules\es6-plato\lib\reporters\eslint\index.js:49:23)
at Object.process (\node_modules\es6-plato\lib\reporters\eslint\index.js:6:16)
at processReporter (\node_modules\es6-plato\lib\plato.js:151:31)
at \node_modules\lodash\lodash.js:4977:15
at baseForOwn (\node_modules\lodash\lodash.js:3020:24)
at \node_modules\lodash\lodash.js:4946:18
at Function.forEach (\node_modules\lodash\lodash.js:9351:14)
at \node_modules\es6-plato\lib\plato.js:146:7
Issue Analytics
- State:
- Created 7 years ago
- Comments:6 (2 by maintainers)
Top Results From Across the Web
ES6 In Depth: let and const - the Web developer blog
(Crunchy syntax details: let is a reserved word in strict mode code. In non-strict-mode code, for the sake of backward compatibility, you can ......
Read more >dojo build systems does not recognize es6 syntax
I have in one project older ES5 modules and new ones in ES6. ... declarations (let, const, function, class) not yet supported outside...
Read more >How to enable ES6 (and beyond) syntax with Node and Express
We need a package that translates ES6 and above syntax to ES5 code. ES5 code is the JS syntax style that is readable...
Read more >"es6" | Can I use... Support tables for HTML5, CSS3, etc
"Can I use" provides up-to-date browser support tables for support of front-end web technologies on desktop and mobile web browsers.
Read more >ECMAScript 6 (ES6): What's New In The Next Version Of ...
Often one would use, for example, the j variable for another iteration in the same scope. But with let , you could safely...
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 Free
Top 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

Brilliant! Cheers for that! 😃
Ok quick followup, @garrymann and @nlindley I know what your problem is with the
globals prop: see here…look at the globals property. Basically the eslint api changed at some point. I updated my readme example to reflect this. It used to be an object
{ require: true }, but now it is an Array['require'].I just pulled down the latest and ran it. Everything is working just fine! Hope that helps 😃 Feel free to open another issue if you have any problems. Sorry if I took too long to respond, yesterday was pretty busy.