JSHint HTML files or other files that contains <script>
tags. Requires node.js
The node modules are included into package.
Just add it to Sublime and choose Tools > Build System > JSHint-inline
Use ⌘ + B
or ⌃ + B
to check all script tags on your HTML file.
** Or use the new shortcut, ⌃ + ⇧ + J
**
They are located on a file called options.js
.
You can override it using JSHint comments like /*global jQuery, console */
To find your options file, you can open Package Manager with ⌘ + ⇧ + P
or ⌃ + ⇧ + P
and type Pack
. Select Preferences: Browse Packages
. Or Go to menu Preferences > Browse Packages
. Go to User > JSHint-Inline
. the file is there.
I've included a file called test.html
with 2 script tags just for testing.
Just click on the install button on nodejs.org
Questions, doubts, comments? Raise an issue
To have the nice success (✓) and error (✗) signs on Sublime's console, you need a font that supports it. If you're on a mac, no problem. For Windows I recommend DejaVu Sans Mono