You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am getting a 'console is not defined. (no-undef)` error. I do have both browser and node defined in my eslint config.
However, when I add /*eslint-env browser*/ to a file with a console statement, I don't get the error. It seems the environment definitions in my eslint.options object are being ignored.
If you put options into the settings file they have to follow the style of the command line / CLIEngine (see doc here: http://eslint.org/docs/developer-guide/nodejs-api#executeontext) For some reason the decided to name env in that case envs and make it an array. Changing this accordingly make everything work. I updated the doc of the eslint setting to make this more clear.
Hi folks,
I am getting a
'console
is not defined. (no-undef)` error. I do have both browser and node defined in my eslint config.However, when I add
/*eslint-env browser*/
to a file with a console statement, I don't get the error. It seems the environment definitions in myeslint.options
object are being ignored.Below is my configuration:
In a test.js file, this throws the
no-undef
error:This does not:
The text was updated successfully, but these errors were encountered: