Skip to content

Commit eccd5e2

Browse files
committed
Merge pull request #434 from nschonni/jshint-cleanup
Jshint cleanup
2 parents 87b9a40 + a218729 commit eccd5e2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

49 files changed

+104
-115
lines changed

.jshintignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
node_modules/
2+
release/
3+
lib/
4+
build/

.jshintrc

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"curly": true,
3+
"immed": true,
4+
"latedef": true,
5+
"newcap": true,
6+
"noarg": true,
7+
"sub": true,
8+
"undef": true,
9+
"boss": true,
10+
"eqnull": true,
11+
"forin": true,
12+
"noempty": true,
13+
"rhino": false,
14+
"jquery": true,
15+
"globals": {
16+
"CSSLint": true
17+
}
18+
}

Gruntfile.js

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -156,24 +156,7 @@ module.exports = function(grunt) {
156156
},
157157
jshint: {
158158
options: {
159-
curly: true,
160-
//eqeqeq: true, TODO: Leaving off due to errors
161-
immed: true,
162-
latedef: true,
163-
newcap: true,
164-
noarg: true,
165-
sub: true,
166-
undef: true,
167-
//unused: true, TODO: Leaving off due to errors around unused instances of CSSLint
168-
boss: true,
169-
eqnull: true,
170-
// Copied from build.xml
171-
forin: true,
172-
noempty: true,
173-
rhino: false,
174-
globals: {
175-
jQuery: true
176-
}
159+
jshintrc: ".jshintrc"
177160
},
178161
gruntfile: {
179162
src: 'Gruntfile.js'

package.json

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,12 @@
4141
},
4242
"devDependencies": {
4343
"grunt": "~0.4.1",
44-
"grunt-contrib-jshint": "~0.5.4",
45-
"grunt-contrib-concat": "~0.3.0",
46-
"grunt-contrib-watch": "~0.4.4",
47-
"yuitest": "~0.7.9",
4844
"grunt-contrib-clean": "~0.4.1",
45+
"grunt-contrib-concat": "~0.3.0",
4946
"grunt-contrib-copy": "~0.4.1",
50-
"grunt-include-replace": "~0.4.0"
47+
"grunt-contrib-jshint": "~0.10.0",
48+
"grunt-contrib-watch": "~0.4.4",
49+
"grunt-include-replace": "~0.4.0",
50+
"yuitest": "~0.7.9"
5151
}
5252
}

src/cli/common.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
* Encapsulates all of the CLI functionality. The api argument simply
33
* provides environment-specific functionality.
44
*/
5-
/*global CSSLint*/
5+
66
function cli(api){
77

88
var globalOptions = {

src/core/Reporter.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/*global CSSLint*/
21
/**
32
* An instance of Report is used to report results of the
43
* verification back to the main API.
@@ -158,4 +157,4 @@ Reporter.prototype = {
158157
};
159158

160159
//expose for testing purposes
161-
CSSLint._Reporter = Reporter;
160+
CSSLint._Reporter = Reporter;

src/core/Util.js

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,3 @@
1-
2-
/*global CSSLint*/
3-
41
/*
52
* Utility functions that make life easier.
63
*/
@@ -59,4 +56,4 @@ CSSLint.Util = {
5956
}
6057
}
6158
}
62-
};
59+
};

src/formatters/checkstyle-xml.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/*global CSSLint*/
21
(function() {
32

43
/**
@@ -106,4 +105,4 @@
106105
}
107106
});
108107

109-
}());
108+
}());

src/formatters/compact.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/*global CSSLint*/
21
CSSLint.addFormatter({
32
//format information
43
id: "compact",

src/formatters/csslint-xml.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
/*global CSSLint*/
21
CSSLint.addFormatter({
32
//format information
43
id: "csslint-xml",
@@ -65,4 +64,4 @@ CSSLint.addFormatter({
6564

6665
return output.join("");
6766
}
68-
});
67+
});

0 commit comments

Comments
 (0)