Closed NoNameProvided closed 9 years ago
If you test on the JSHint site yourself, and turn off "Assume browser", you get the same result. I think the extension is doing it right. You may not be writing code for the browser, so it should flag window imo.
I know that is the correct behaviour from the JSLint, but is this the correct behaviour from the extension? Brackets is mainly a front-end developer tool. "Coding for the web." So maybe it is a good idea to turn on the "Assume browser" option. But it is your's choice.
My vote would be to make use of .jshintrc at the project level to set the option.
JSLint don't recognize that 'window' (window.navigator.userAgent;) is a global variable, and display a warning like this:
'window' is not defined. (W117)
will supress this warning, but it should know that is a global.