Skip to content

Commit

Permalink
feat: update ESLint config (#15)
Browse files Browse the repository at this point in the history
* feat: update ESLint config

* ci: add changesets
  • Loading branch information
donniean authored Oct 29, 2024
1 parent 903e247 commit 20bde43
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
5 changes: 5 additions & 0 deletions .changeset/eight-dots-hunt.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'eslint-config-kubesphere': patch
---

feat: update ESLint config
5 changes: 3 additions & 2 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ module.exports = {
commonjs: true,
browser: true,
},
extends: ['airbnb-typescript', 'plugin:prettier/recommended'],
extends: ['airbnb-typescript', 'plugin:react-hooks/recommended', 'prettier'],
plugins: ['@typescript-eslint', 'react', 'babel', 'promise', 'import'],
settings: {
react: {
Expand All @@ -34,7 +34,8 @@ module.exports = {
{
code: 100,
ignoreComments: true,
ignorePattern: '^(\\s*[a-zA-Z_]+: \'[^\']+\'[,;]*)|(.*interpolate.*)|(.*require.*)|(.*_\\.template.*)|(<svg .*)|(<rect .*)|(<polygon .*)$',
ignorePattern:
"^(\\s*[a-zA-Z_]+: '[^']+'[,;]*)|(.*interpolate.*)|(.*require.*)|(.*_\\.template.*)|(<svg .*)|(<rect .*)|(<polygon .*)$",
ignoreRegExpLiterals: true,
ignoreTrailingComments: true,
ignoreUrls: true,
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@
"@typescript-eslint/parser": "^5.1.0",
"eslint": "^7.32.0",
"eslint-config-airbnb-typescript": "^14.0.1",
"eslint-config-prettier": "^8.5.0",
"eslint-config-prettier": "^9.1.0",
"eslint-friendly-formatter": "^4.0.1",
"eslint-plugin-babel": "^5.3.0",
"eslint-plugin-import": "^2.25.2",
"eslint-plugin-jsx-a11y": "^6.4.1",
"eslint-plugin-prettier": "^4.2.1",
"eslint-plugin-promise": "^5.1.0",
"eslint-plugin-react": "^7.26.1"
"eslint-plugin-react": "^7.26.1",
"eslint-plugin-react-hooks": "^5.0.0"
}
}

0 comments on commit 20bde43

Please sign in to comment.