-
-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
### UPDATED - Package dependencies. - Re-configured ESLint linting options. - Report URL changed. - Minor changes to Config UI. - During try catch, caught error objects will now be checked before serializing. ### FIXED - Some types ended with `,` instead of `;`. - Some types did not properly separated with `:`. - Imports for React components should not end with `.js` file extension. - The form select for setup verification method is missing the `key` prop. ### ADDED - Security panel support for "DSC Impassa/SCW". - Package version in title when debug information is sent to plugin author.
- Loading branch information
1 parent
3dfcc8b
commit 93c1609
Showing
26 changed files
with
1,275 additions
and
783 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,91 @@ | ||
import javascriptPlugin from '@eslint/js'; | ||
import stylisticPlugin from '@stylistic/eslint-plugin'; | ||
import typescriptPlugin from '@typescript-eslint/eslint-plugin'; | ||
import typescriptParser from '@typescript-eslint/parser'; | ||
import importPlugin from 'eslint-plugin-import'; | ||
import jsxA11yPlugin from 'eslint-plugin-jsx-a11y'; | ||
import reactPlugin from 'eslint-plugin-react'; | ||
import reactHooksPlugin from 'eslint-plugin-react-hooks'; | ||
import globals from 'globals'; | ||
|
||
/** | ||
* ESLint config. | ||
* | ||
* @type {import('eslint').Linter.Config[]} | ||
* | ||
* @since 1.0.0 | ||
*/ | ||
const eslintConfig = [ | ||
{ | ||
name: 'preferred-rules', | ||
files: [ | ||
'**/*.js', | ||
'**/*.mjs', | ||
'**/*.cjs', | ||
'**/*.jsx', | ||
'**/*.ts', | ||
'**/*.mts', | ||
'**/*.cts', | ||
'**/*.tsx', | ||
], | ||
languageOptions: { | ||
globals: { | ||
...globals.browser, | ||
...globals.node, | ||
NodeJS: 'readonly', | ||
}, | ||
parser: typescriptParser, | ||
parserOptions: { | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
ecmaVersion: 'latest', | ||
project: './tsconfig.json', | ||
sourceType: 'module', | ||
}, | ||
}, | ||
plugins: { | ||
'@stylistic': stylisticPlugin, | ||
'@typescript-eslint': typescriptPlugin, | ||
'import': importPlugin, | ||
'jsx-a11y': jsxA11yPlugin, | ||
react: reactPlugin, | ||
'react-hooks': reactHooksPlugin, | ||
}, | ||
settings: { | ||
'import/resolver': { | ||
typescript: { | ||
project: './tsconfig.json', | ||
}, | ||
}, | ||
react: { | ||
version: 'detect', | ||
}, | ||
}, | ||
rules: { | ||
...importPlugin.configs.recommended.rules, | ||
...javascriptPlugin.configs.recommended.rules, | ||
...jsxA11yPlugin.configs.recommended.rules, | ||
...reactPlugin.configs.recommended.rules, | ||
...reactHooksPlugin.configs.recommended.rules, | ||
...stylisticPlugin.configs['recommended-flat'].rules, | ||
...typescriptPlugin.configs.recommended.rules, | ||
'@stylistic/arrow-parens': ['error', 'always'], | ||
'@stylistic/brace-style': ['error', '1tbs'], | ||
'@stylistic/comma-dangle': ['error', 'always-multiline'], | ||
'@stylistic/member-delimiter-style': ['error', { singleline: { requireLast: true } }], | ||
'@stylistic/multiline-ternary': ['off'], | ||
'@stylistic/quote-props': ['error', 'as-needed'], | ||
'@stylistic/quotes': ['error', 'single'], | ||
'@stylistic/semi': ['error', 'always'], | ||
'@typescript-eslint/no-explicit-any': ['off'], | ||
'@typescript-eslint/no-unused-vars': ['error'], | ||
'import/order': ['error', { alphabetize: { order: 'asc' } }], | ||
'no-console': ['warn', { allow: ['error', 'info', 'warn'] }], | ||
'no-irregular-whitespace': ['error', { skipComments: true }], | ||
'no-unused-vars': ['off'], | ||
}, | ||
}, | ||
]; | ||
|
||
export default eslintConfig; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.