Skip to content

Commit

Permalink
feat(eslint): enable reportUnusedDisableDirectives (#914)
Browse files Browse the repository at this point in the history
  • Loading branch information
ybiquitous committed Apr 2, 2021
1 parent 3d08a69 commit f40e189
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/init.js
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ const initCommand = (baseDir, logger) => {
};

return {
// eslint-disable-next-line max-statements
// eslint-disable-next-line max-statements, max-lines-per-function
async updatePackageFile() {
const packageInfo = JSON.parse(await readFile("package.json"));

Expand Down Expand Up @@ -97,6 +97,7 @@ const initCommand = (baseDir, logger) => {
packageInfo.eslintConfig = {
root: true,
extends: ["ybiquitous"],
reportUnusedDisableDirectives: true,
};

// Delete husky v4 configuration.
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,7 @@
"ignorePatterns": [
"coverage"
],
"reportUnusedDisableDirectives": true,
"extends": [
"ybiquitous/node"
],
Expand Down
2 changes: 2 additions & 0 deletions test/__snapshots__/init.test.js.snap
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ Object {
"extends": Array [
"ybiquitous",
],
"reportUnusedDisableDirectives": true,
"root": true,
},
"lint-staged": Object {
Expand Down Expand Up @@ -88,6 +89,7 @@ Object {
"extends": Array [
"ybiquitous",
],
"reportUnusedDisableDirectives": true,
"root": true,
},
"lint-staged": Object {
Expand Down

0 comments on commit f40e189

Please sign in to comment.