You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Linting inline JavaScript in HTML files does not seem to work for me in SublimeText 2. I noticed that you are extracting the JavaScript 'manually'. Why not use the functionality provided by jshint itself?
var extract = require('jshint/src/cli').extract;
var js = extract(html, 'auto');
Linting JS inside HTML should work properly now. It'd still be nice to switch to jshint's extract method. At the moment, js is regexed out of the markup.
victorporof
changed the title
Inline JavaScript linting not working
Use JsHint's extract method to lint inline JavaScript
Oct 27, 2014
victorporof
changed the title
Use JsHint's extract method to lint inline JavaScript
Use JsHint's extract method to lint inline JavaScript, instead of our home-backed regexes
Dec 7, 2014
Linting inline JavaScript in HTML files does not seem to work for me in SublimeText 2. I noticed that you are extracting the JavaScript 'manually'. Why not use the functionality provided by jshint itself?
See http://www.jshint.com/docs/cli/
The text was updated successfully, but these errors were encountered: