Skip to content

Commit

Permalink
update eslint and associated packages
Browse files Browse the repository at this point in the history
  • Loading branch information
ianhi committed Feb 3, 2022
1 parent f0b7986 commit 184965e
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 17 deletions.
16 changes: 13 additions & 3 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,20 @@ module.exports = {
'@typescript-eslint/ban-ts-ignore': 'off', //stackoverflow.com/questions/59729654/how-ignore-typescript-errors-with-ts-ignore
'@typescript-eslint/camelcase': 'off',
'@typescript-eslint/explicit-function-return-type': 'off',
'@typescript-eslint/interface-name-prefix': [
'@typescript-eslint/naming-convention': [ // https://stackoverflow.com/questions/62915344/eslint-erro-when-adding-rule-typescript-eslint-interface-name-prefix
"error",
{
"selector": "interface",
"format": ["PascalCase"],
"custom": {
"regex": "^I[A-Z]",
"match": true
}
}
],
'@typescript-eslint/ban-ts-comment': [
'error',
{ prefixWithI: 'always' },
{'ts-ignore': false},
],
'@typescript-eslint/no-unused-vars': ['warn', { args: 'none' }],
'@typescript-eslint/no-explicit-any': 'off',
Expand All @@ -39,4 +50,3 @@ module.exports = {
'prefer-arrow-callback': 'error'
}
};

17 changes: 3 additions & 14 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -69,15 +69,14 @@
"@types/mocha": "^5.2.5",
"@types/node": "^10.11.6",
"@types/webpack-env": "^1.13.6",
"@typescript-eslint/eslint-plugin": "^2.31.0",
"@typescript-eslint/parser": "^2.31.0",
"@typescript-eslint/eslint-plugin": "^5.10.0",
"@typescript-eslint/parser": "^5.10.0",
"css-loader": "^3.2.0",
"eslint": "^6.8.0",
"eslint": "^8.0.0",
"eslint-config-prettier": "^6.11.0",
"eslint-plugin-prettier": "^3.1.3",
"expect.js": "^0.3.1",
"fs-extra": "^7.0.0",
"husky": "^4.2.5",
"karma": "^6.0.0",
"karma-chrome-launcher": "^2.2.0",
"karma-firefox-launcher": "^1.1.0",
Expand Down Expand Up @@ -108,16 +107,6 @@
}
}
},
"husky": {
"hooks": {
"pre-commit": "lint-staged"
}
},
"lint-staged": {
"*.ts": [
"eslint . --ext .ts --fix"
]
},
"prettier": {
"singleQuote": true
}
Expand Down

0 comments on commit 184965e

Please sign in to comment.