Skip to content

Commit 25d8ccd

Browse files
authored
Build: Improve ESLint configuration (#3188)
* Bump eslint-config-jquery package to 0.1.4 version * Add subtask "dist" to "eslint" task and add it to the build task list * Make gitignore globs more flexible for the "dist" folder Fixes gh-3169
1 parent 58c6ca9 commit 25d8ccd

File tree

3 files changed

+7
-3
lines changed

3 files changed

+7
-3
lines changed

.gitignore

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,10 @@
1010

1111
npm-debug.log
1212

13-
/dist/jquery*
13+
# Ignore everything in dist folder except for eslint config
14+
/dist/*
15+
!/dist/.eslintrc
16+
1417
/node_modules
1518

1619
/test/node_smoke_tests/lib/ensure_iterability.js

Gruntfile.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ module.exports = function( grunt ) {
109109
quiet: true
110110
},
111111
all: ".",
112+
dist: "dist/jquery.js",
112113
dev: [ "src/**/*.js", "Gruntfile.js", "test/**/*.js", "build/**/*.js" ]
113114
},
114115
testswarm: {
@@ -201,7 +202,7 @@ module.exports = function( grunt ) {
201202
]
202203
);
203204

204-
grunt.registerTask( "default", [ "dev", "test_fast", "compare_size" ] );
205+
grunt.registerTask( "default", [ "dev", "eslint:dist", "test_fast", "compare_size" ] );
205206

206207
grunt.registerTask( "precommit_lint", [ "newer:jsonlint", "newer:eslint:all" ] );
207208
};

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
"commitplease": "2.3.1",
3030
"core-js": "2.2.2",
3131
"cross-spawn": "2.2.3",
32-
"eslint-config-jquery": "0.1.2",
32+
"eslint-config-jquery": "0.1.6",
3333
"grunt": "1.0.1",
3434
"grunt-babel": "6.0.0",
3535
"grunt-cli": "1.2.0",

0 commit comments

Comments
 (0)