mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
Improves handling of EOL whitespace error reporting
This commit is contained in:
parent
dd900460ac
commit
b6a2dfbeb9
@ -25,12 +25,12 @@ if ( jshint( src, config ) ) {
|
||||
jshint.errors.forEach(function( e ) {
|
||||
if ( !e ) { return; }
|
||||
|
||||
var str = e.evidence ? e.evidence : "";
|
||||
var str = e.evidence ? e.evidence : "",
|
||||
character = e.character === true ? "EOL" : "C" + e.character;
|
||||
|
||||
if ( str ) {
|
||||
str = str.replace( /\t/g, " " ).trim();
|
||||
|
||||
console.log( " [L" + e.line + ":C" + e.character + "] " + e.reason + "\n " + str + "\n");
|
||||
console.log( " [L" + e.line + ":" + character + "] " + e.reason + "\n " + str + "\n");
|
||||
}
|
||||
});
|
||||
}
|
Loading…
Reference in New Issue
Block a user