Is it possible to enable ES6 features in the jslint plugin for Notepad++?
I tried setting the option es6 and ES6 to true but that doesn't seem to work.
Specifically I'm using the arrow functions "=>" and getting jslint errors saying expected an identifier and saw ">".
This is for programs running under node.js v 4.2.1 using notepad++ as the editor in a Windows 2012 R2 environment.
Is it possible to enable ES6 features in the jslint plugin for Notepad++?
I tried setting the option es6 and ES6 to true but that doesn't seem to work.
Specifically I'm using the arrow functions "=>" and getting jslint errors saying expected an identifier and saw ">".
This is for programs running under node.js v 4.2.1 using notepad++ as the editor in a Windows 2012 R2 environment.
Share Improve this question edited Oct 22, 2015 at 20:12 ciso asked Oct 22, 2015 at 17:04 cisociso 3,0507 gold badges37 silver badges64 bronze badges 5- Can you replace a jslint.js file anywhere in Notepad++? – ruffin Commented Oct 22, 2015 at 18:59
- I couldn't find one to replace. The plugin is in a JSLintNpp.dll library file downloaded from sourceforge/projects/jslintnpp – ciso Commented Oct 22, 2015 at 20:00
- I don't really think JSLint supports es6. You'll need to use something like ESLint. – user1726343 Commented Oct 22, 2015 at 20:19
- @Asad Saeeduddin According to github./douglascrockford/JSLint/blob/master/jslint.html it does: " <div><label><input title=es6 type=checkbox>ES6</label></div>" Either I don't know how to enable it in notepad++ or it hasn't been implemted there. Wonderring if anyone else has been able to use jslint in notepad++ for es6. Also here: jslint. – ciso Commented Oct 22, 2015 at 21:58
- @AsadSaeeduddin In the latest version (check jslint.) it does. Been out a couple of months. Will have to check notepad++ next time I'm in front of a Windows box. – ruffin Commented Oct 23, 2015 at 5:09
2 Answers
Reset to default 2Found the answer. Add
/*jslint es6:true*/
at the beginning of the program and get the latest jslint plugin for notepad++ at http://sourceforge/projects/jslintnpp/
Add at the beginning of your code:
/*jslint esnext:true*/
发布者:admin,转转请注明出处:http://www.yc00.com/questions/1745203443a4616463.html
评论列表(0条)