Skip to content

Commit 697c58e

Browse files
Merge pull request #13563 from Snuffleupagus/eslint-plugin-json
Add basic linting of JSON files using `eslint-plugin-json`
2 parents 246d565 + 1cfaf07 commit 697c58e

File tree

5 files changed

+59
-2
lines changed

5 files changed

+59
-2
lines changed

.eslintrc

+2
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,15 @@
66

77
"plugins": [
88
"import",
9+
"json",
910
"mozilla",
1011
"no-unsanitized",
1112
"sort-exports",
1213
"unicorn",
1314
],
1415

1516
"extends": [
17+
"plugin:json/recommended",
1618
"plugin:prettier/recommended"
1719
],
1820

gulpfile.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -1742,7 +1742,7 @@ gulp.task("lint", function (done) {
17421742
const esLintOptions = [
17431743
"node_modules/eslint/bin/eslint",
17441744
"--ext",
1745-
".js,.jsm",
1745+
".js,.jsm,.json",
17461746
".",
17471747
"--report-unused-disable-directives",
17481748
];

package-lock.json

+54
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
"eslint-plugin-fetch-options": "^0.0.5",
2323
"eslint-plugin-html": "^6.1.2",
2424
"eslint-plugin-import": "^2.23.4",
25+
"eslint-plugin-json": "^3.0.0",
2526
"eslint-plugin-mozilla": "^2.10.0",
2627
"eslint-plugin-no-unsanitized": "^3.1.5",
2728
"eslint-plugin-prettier": "^3.4.0",

test/types/tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,5 +22,5 @@
2222
},
2323
"files": [
2424
"main.ts"
25-
],
25+
]
2626
}

0 commit comments

Comments
 (0)