I used the following plugin to install jslint for vim: https://github.com/hallettj/jslint.vim .
I'm a bit confused as to how to configure this.
I see a list of options here http://www.jslint.com/lint.html#options , but
in the jslint-vim plugin, where do I specify these options?
Create a .jslintrc in your home directory. The options are listed in a /**/
comment block. There's an example in the documentation under Usage . Options set in your .jslintrc will apply to jslint generally, not just the vim plugin.
What is the option for removing indenting errors
Try setting white
: tolerate messy whitespace . But this will cause other issues to pass.
Put this in your .jslintrc :
/*jslint white: true */
What is the option to remove the "x variable was used before it was defined?"
The option is named undef
. Put this in your .jslintrc :
/*jslint undef: true */
Putting those two options together:
/*jslint white: true, undef: true */
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.