You may be breaking the JSON structure, expected by jshint. Try putting a single line:
“esversion”: 6,
note the comma at the end, between smarttabs and globals.
Also, creating the .jshintrc file in an user’s home directory enables it for all projects by that user.
Cheers!
]]>I already have a .jshintrc file. Its contents are as follows
{
“curly”: true,
“eqeqeq”: true,
“immed”: true,
“latedef”: true,
“newcap”: true,
“noarg”: true,
“sub”: true,
“undef”: true,
“boss”: true,
“eqnull”: true,
“browser”: true,
“smarttabs”: true,
“globals”: {
“jQuery”: true,
“angular”: true,
“console”: true,
“$”: true,
“_”: true,
“moment”: true,
“describe”: true,
“beforeEach”: true,
“module”: true,
“inject”: true,
“it”: true,
“expect”: true,
“xdescribe”: true,
“xit”: true,
“spyOn”: true
}
}
When i try to add
{
“esversion”: 6
}, it still gives me an error
Thanks!
]]>Great point Shailesh! Ya, the filename is just .jshintrc . Files beginning with a dot are hidden files and can be used to help configure things (there’s also .gitignore, .babelrc, .bashrc, etc.) Fun fact: the ‘rc’ at the end seems to stand for ‘runcom’ or ‘run commands’ (http://unix.stackexchange.com/questions/3467/what-does-rc-in-bashrc-stand-for) .
]]>