So there is an option to ignore files in jshint, but it’s not set within .jshintrc
but rather a separate file .jshintignore
, which makes sense. However, while jshint will look for .jshintrc
in your project’s subdirectories, .jshintignore
needs to be in the project root. So with Twitter Bootstrap, .jshintrc
is in /js
while .jshintignore
needs to be placed in /
.
So to solve the problem in my question /.jshintignore
needs to contain:
js/html5.js
js/theme-customizer.js
And that’s it!