Closed ghost closed 8 years ago
Where are you seeing that error? If you are seeing it from trying to run the plugin then you are using a very out of date version of Atom.
Actually, this package still uses Coffee script, so that couldn't have come from the package....
I am using Atom 1.4.3 with the recently installed JSHint a few days ago
the warning message i get:
W104 - 'const' is not available in ES6 (use 'eversion: 6') or Mozilla JS extensions (use moz)
the line of codes: " Anything with const or let will trigger a warning "
const BrowserWindow = electron.BrowserWindow;
let mainWindow;
@brody182 Have you set esversion
to 6
in your .jshintrc
?
http://jshint.com/docs/options/#esversion
where is the .jshintrc file? mac OS X
You should create one in your project root. There's a lot of tutorial and docs out there about getting started with JSHint, I would recommend you read them.
Closing as not a bug in linter-jshint, feel free to continue the discussion
actually just add this /jshint esversion: 6 /
configuring .jshintrc
in your project with /*jshint esversion: 6 */
might throw exceptions when saving a document in Atom (currently: 1.8.0) since it is not in JSON format. Another way is:
{
"esversion":6
}
@amandeepmittal That format is meant for inline configuration, as you show the proper format for .jshintrc
files is the JSON method.
@Arcanemagus meaning that /*jshint esversion: 6 */
should be used in a single .js
file instead of .jshintrc
file?
That's what the Configuration section of the JSHint docs say at least 😉.
@Arcanemagus that's right. I did not look the JSHint docs in depth.
Can someone explain why this just can't be built into the plugin as a setting? Just curious.
You should be saving the configuration of your linting tools in the project, so anyone working on them gets the same configuration. The only settings in this wrapper package should be things that can't be configured like that.
This issue was resolved 3 years ago, closing and locking 😉.
error message: 'const' is available in ES6 (use 'eversion: 6') or mozilla JS extension
Why isn't the linter using the latest version if JS?