Permalink
Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Fix #10692. JSLint is dead! Long live JSHint!
Still needs this sizzle PR: jquery/sizzle#82
- Loading branch information
1 parent
d6500cc
commit 98386cfd775fdfa7837ccbec173b04f1e6d57896
Showing
10 changed files
with
4,323 additions
and
5,570 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@@ -0,0 +1,35 @@ | ||
var JSHINT = require("./lib/jshint").JSHINT, | ||
print = require("sys").print, | ||
src = require("fs").readFileSync("dist/jquery.js", "utf8"); | ||
|
||
JSHINT(src, { | ||
evil: true, | ||
undef: false, | ||
browser: true, | ||
wsh: true, | ||
eqnull: true, | ||
expr: true, | ||
curly: true, | ||
eqeq: true, | ||
trailing: true, | ||
predef: [ | ||
"define", | ||
"DOMParser" | ||
], | ||
maxerr: 100 | ||
}); | ||
|
||
var e = JSHINT.errors, found = e.length, i = 0, w; | ||
|
||
for ( ; i < e.length; i++ ) { | ||
w = e[i]; | ||
|
||
print( "\n" + w.evidence + "\n" ); | ||
print( " Problem at line " + w.line + " character " + w.character + ": " + w.reason ); | ||
} | ||
|
||
if ( found > 0 ) { | ||
print( "\n" + found + " Error(s) found.\n" ); | ||
} else { | ||
print( "JSHint check passed.\n" ); | ||
} |
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
lint
is an alias tohint
then you runhint
i'm pretty sure thelint
here is not needed