Closed cbranca closed 6 years ago
Huh, strange! Looking into it
After tinkering a bit, It looks like it works when running via command line but its not working in my editor (VS Code with the standard plugin). Could you confirm that running semistandard
via terminal works?
Are you experiencing the same issue in your editor? What are you using?
I suspect the issue is happening due to some standard-engine
changes:
https://github.com/standard/standard-engine/blob/master/index.js#L60
By default, using lintText
will not use package.json values. So, if editor plugins are using this function they will not include values defined under the semistandard
key in package.json (including globals).
Can you test to see if any of this is true for your setup?
Hi Flet, the problem occurs within editors. I tried both Sublime Text 3 and Visual Studio Code.
Thanks to @feross, this was fixed in standard-engine
.
I updated semistandard
to 12.0.1 which should fix this issue. Could you give it a try?
Hi @Flet , sorry for the delay of my answer. I tried version 12.0.1 just now and it works. Thank you 💯
With version 10.0.0 if I wanted to exclude global variables like "angular" or "$" I had to put this in package.json:
"semistandard": { "globals": ["angular","$"] },
But after the 12.0.0 update I keep getting "[semistandard] angular (or $) is not defined.. (no-undef)" instead of excluding "angular" and "$" global variables. Is it a bug?