2022-02-19 16:05:21 +01:00
|
|
|
{
|
|
|
|
"root": true,
|
2024-07-10 13:02:54 +02:00
|
|
|
"plugins": ["promise", "unicorn"],
|
2022-02-19 16:05:21 +01:00
|
|
|
"env": {
|
|
|
|
"browser": true,
|
|
|
|
"node": true,
|
2023-07-02 15:54:50 +02:00
|
|
|
"es2024": true
|
2022-02-19 16:05:21 +01:00
|
|
|
},
|
|
|
|
"parserOptions": {
|
2023-07-02 15:54:50 +02:00
|
|
|
"ecmaVersion": "latest",
|
2022-02-19 16:05:21 +01:00
|
|
|
"sourceType": "module",
|
|
|
|
"ecmaFeatures": {
|
|
|
|
"jsx": true
|
2022-02-20 12:36:37 +01:00
|
|
|
}
|
2022-02-19 16:05:21 +01:00
|
|
|
},
|
|
|
|
"rules": {
|
|
|
|
"constructor-super": "error",
|
|
|
|
"for-direction": "error",
|
|
|
|
"getter-return": "error",
|
|
|
|
"no-async-promise-executor": "error",
|
|
|
|
"no-class-assign": "error",
|
|
|
|
"no-compare-neg-zero": "error",
|
|
|
|
"no-cond-assign": "error",
|
|
|
|
"no-const-assign": "error",
|
2024-02-08 21:57:58 +01:00
|
|
|
"no-constant-binary-expression": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-constant-condition": "error",
|
|
|
|
"no-constructor-return": "error",
|
|
|
|
"no-control-regex": "error",
|
|
|
|
"no-debugger": "error",
|
|
|
|
"no-dupe-args": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-dupe-class-members": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-dupe-else-if": "error",
|
|
|
|
"no-dupe-keys": "error",
|
|
|
|
"no-duplicate-case": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-duplicate-imports": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-empty-character-class": "error",
|
|
|
|
"no-empty-pattern": "error",
|
|
|
|
"no-ex-assign": "error",
|
|
|
|
"no-fallthrough": "error",
|
|
|
|
"no-func-assign": "error",
|
|
|
|
"no-import-assign": "error",
|
|
|
|
"no-invalid-regexp": "error",
|
|
|
|
"no-irregular-whitespace": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-loss-of-precision": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-misleading-character-class": "error",
|
2023-02-06 23:36:21 +01:00
|
|
|
"no-new-native-nonconstructor": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-new-symbol": "error",
|
|
|
|
"no-obj-calls": "error",
|
|
|
|
"no-promise-executor-return": "error",
|
|
|
|
"no-prototype-builtins": "error",
|
|
|
|
"no-self-assign": "error",
|
|
|
|
"no-self-compare": "error",
|
|
|
|
"no-setter-return": "error",
|
2024-02-08 22:09:31 +01:00
|
|
|
"no-sparse-arrays": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-this-before-super": "error",
|
|
|
|
"no-undef": "error",
|
|
|
|
"no-unexpected-multiline": "error",
|
|
|
|
"no-unmodified-loop-condition": "error",
|
|
|
|
"no-unreachable": "error",
|
|
|
|
"no-unreachable-loop": "error",
|
|
|
|
"no-unsafe-finally": "error",
|
|
|
|
"no-unsafe-negation": "error",
|
|
|
|
"no-unsafe-optional-chaining": "error",
|
|
|
|
"no-unused-private-class-members": "error",
|
2023-02-06 23:42:09 +01:00
|
|
|
"no-unused-vars": ["error", { "varsIgnorePattern": "^_" }],
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-use-before-define": [
|
2022-02-19 16:05:21 +01:00
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"functions": false,
|
|
|
|
"classes": false,
|
2022-02-20 12:36:37 +01:00
|
|
|
"variables": false
|
2022-02-19 16:05:21 +01:00
|
|
|
}
|
|
|
|
],
|
|
|
|
"no-useless-backreference": "error",
|
|
|
|
"use-isnan": [
|
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"enforceForSwitchCase": true,
|
|
|
|
"enforceForIndexOf": true
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"valid-typeof": ["error", { "requireStringLiterals": true }],
|
|
|
|
|
|
|
|
"consistent-this": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"default-param-last": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"default-case-last": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"dot-notation": ["error", { "allowKeywords": true }],
|
2022-02-19 16:42:47 +01:00
|
|
|
"eqeqeq": ["error", "always", { "null": "ignore" }],
|
2022-02-19 16:05:21 +01:00
|
|
|
"grouped-accessor-pairs": "error",
|
|
|
|
"new-cap": [
|
|
|
|
"error",
|
|
|
|
{ "newIsCap": true, "capIsNew": false, "properties": true }
|
|
|
|
],
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-array-constructor": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-caller": "error",
|
|
|
|
"no-delete-var": "error",
|
|
|
|
"no-empty": ["error", { "allowEmptyCatch": true }],
|
2024-02-08 22:09:31 +01:00
|
|
|
"no-empty-static-block": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-eval": "error",
|
|
|
|
"no-global-assign": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-implied-eval": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-multi-str": "error",
|
|
|
|
"no-new-func": "error",
|
2023-10-18 13:04:31 +02:00
|
|
|
"no-object-constructor": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-octal": "error",
|
|
|
|
"no-octal-escape": "error",
|
|
|
|
"no-proto": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-redeclare": ["error", { "builtinGlobals": false }],
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-regex-spaces": "error",
|
|
|
|
"no-shadow-restricted-names": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-throw-literal": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-undef-init": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-unused-expressions": [
|
2022-02-19 16:05:21 +01:00
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"allowShortCircuit": true,
|
|
|
|
"allowTernary": true,
|
|
|
|
"allowTaggedTemplates": true
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"no-useless-call": "error",
|
2024-02-08 22:25:31 +01:00
|
|
|
"no-useless-concat": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-useless-computed-key": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-useless-constructor": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-useless-escape": "error",
|
|
|
|
"no-useless-rename": "error",
|
|
|
|
"no-useless-return": "error",
|
2024-02-08 22:24:19 +01:00
|
|
|
"no-else-return": ["error", { "allowElseIf": false }],
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-var": "error",
|
2024-05-21 17:53:33 +02:00
|
|
|
"no-void": ["error", { "allowAsStatement": true }],
|
2022-02-19 16:05:21 +01:00
|
|
|
"no-with": "error",
|
|
|
|
"object-shorthand": ["error", "properties"],
|
|
|
|
"one-var": ["error", { "initialized": "never" }],
|
|
|
|
"prefer-const": ["error", { "destructuring": "all" }],
|
|
|
|
"prefer-object-has-own": "error",
|
|
|
|
"prefer-promise-reject-errors": "error",
|
|
|
|
"prefer-regex-literals": ["error", { "disallowRedundantWrapping": true }],
|
|
|
|
"radix": "error",
|
|
|
|
"yoda": ["error", "never"],
|
2022-08-31 13:22:20 +02:00
|
|
|
"curly": ["error", "all"],
|
2022-08-31 13:44:54 +02:00
|
|
|
"func-style": ["error", "expression"],
|
2022-08-31 13:49:03 +02:00
|
|
|
"prefer-arrow-callback": "error",
|
2022-08-31 13:27:37 +02:00
|
|
|
"arrow-body-style": ["error", "always"],
|
2022-02-19 16:05:21 +01:00
|
|
|
|
|
|
|
"promise/param-names": "error",
|
|
|
|
"promise/no-new-statics": "error",
|
2024-02-08 22:32:39 +01:00
|
|
|
"promise/no-multiple-resolved": "error",
|
2024-02-08 22:34:10 +01:00
|
|
|
"promise/no-nesting": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
|
|
|
|
"unicorn/better-regex": "error",
|
|
|
|
"unicorn/catch-error-name": "error",
|
2023-07-18 21:37:00 +02:00
|
|
|
"unicorn/consistent-destructuring": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"unicorn/custom-error-definition": "error",
|
|
|
|
"unicorn/error-message": "error",
|
|
|
|
"unicorn/escape-case": "error",
|
2023-07-18 21:43:06 +02:00
|
|
|
"unicorn/explicit-length-check": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"unicorn/new-for-builtins": "error",
|
2023-07-18 21:45:37 +02:00
|
|
|
"unicorn/no-array-callback-reference": "error",
|
2023-07-18 21:46:32 +02:00
|
|
|
"unicorn/no-array-for-each": "error",
|
2023-07-18 21:48:07 +02:00
|
|
|
"unicorn/no-array-method-this-argument": "error",
|
2023-07-18 21:50:47 +02:00
|
|
|
"unicorn/no-document-cookie": "error",
|
2023-07-18 21:51:51 +02:00
|
|
|
"unicorn/no-empty-file": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"unicorn/no-hex-escape": "error",
|
|
|
|
"unicorn/no-instanceof-array": "error",
|
2023-07-18 21:53:56 +02:00
|
|
|
"unicorn/no-new-array": "error",
|
2023-07-18 21:54:53 +02:00
|
|
|
"unicorn/no-new-buffer": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"unicorn/no-this-assignment": "error",
|
|
|
|
"unicorn/no-zero-fractions": "error",
|
2023-07-18 21:58:04 +02:00
|
|
|
"unicorn/number-literal-case": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"unicorn/prefer-node-protocol": "error",
|
2022-11-21 09:08:19 +01:00
|
|
|
"unicorn/throw-new-error": "error",
|
2023-07-18 22:00:19 +02:00
|
|
|
"unicorn/no-typeof-undefined": "error",
|
2023-07-18 22:02:15 +02:00
|
|
|
"unicorn/require-array-join-separator": "error",
|
2023-07-18 22:04:34 +02:00
|
|
|
"unicorn/prefer-number-properties": "error",
|
2023-07-18 22:08:49 +02:00
|
|
|
"unicorn/prefer-modern-math-apis": "error",
|
2024-09-17 23:58:02 +02:00
|
|
|
"unicorn/prefer-structured-clone": "error",
|
2023-07-18 22:08:49 +02:00
|
|
|
"unicorn/template-indent": "error"
|
2022-02-19 16:05:21 +01:00
|
|
|
},
|
|
|
|
"overrides": [
|
|
|
|
{
|
|
|
|
"files": ["*.ts", "*.tsx"],
|
2022-02-20 12:36:37 +01:00
|
|
|
"parser": "@typescript-eslint/parser",
|
|
|
|
"plugins": ["@typescript-eslint"],
|
2022-02-19 16:05:21 +01:00
|
|
|
"rules": {
|
2022-02-19 22:08:50 +01:00
|
|
|
"no-undef": "off",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-dupe-class-members": "off",
|
|
|
|
"@typescript-eslint/no-dupe-class-members": "error",
|
|
|
|
"no-unused-vars": "off",
|
2023-02-06 23:42:09 +01:00
|
|
|
"@typescript-eslint/no-unused-vars": [
|
|
|
|
"error",
|
|
|
|
{ "varsIgnorePattern": "^_" }
|
|
|
|
],
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-use-before-define": "off",
|
|
|
|
"@typescript-eslint/no-use-before-define": [
|
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"functions": false,
|
|
|
|
"classes": false,
|
|
|
|
"enums": false,
|
|
|
|
"variables": false,
|
|
|
|
"typedefs": false
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"default-param-last": "off",
|
|
|
|
"@typescript-eslint/default-param-last": "error",
|
|
|
|
"dot-notation": "off",
|
|
|
|
"@typescript-eslint/dot-notation": ["error", { "allowKeywords": true }],
|
|
|
|
"no-array-constructor": "off",
|
|
|
|
"@typescript-eslint/no-array-constructor": "error",
|
|
|
|
"no-implied-eval": "off",
|
|
|
|
"@typescript-eslint/no-implied-eval": "error",
|
|
|
|
"no-redeclare": "off",
|
|
|
|
"@typescript-eslint/no-redeclare": [
|
|
|
|
"error",
|
|
|
|
{ "builtinGlobals": false }
|
|
|
|
],
|
|
|
|
"no-throw-literal": "off",
|
2024-09-17 23:43:56 +02:00
|
|
|
"@typescript-eslint/only-throw-error": "error",
|
2022-02-20 12:36:37 +01:00
|
|
|
"no-unused-expressions": "off",
|
|
|
|
"@typescript-eslint/no-unused-expressions": [
|
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"allowShortCircuit": true,
|
|
|
|
"allowTernary": true,
|
|
|
|
"allowTaggedTemplates": true
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"no-useless-constructor": "off",
|
|
|
|
"@typescript-eslint/no-useless-constructor": "error",
|
2024-09-17 23:43:56 +02:00
|
|
|
"@typescript-eslint/no-unnecessary-template-expression": "error",
|
2024-09-25 18:02:43 +02:00
|
|
|
"@typescript-eslint/no-unnecessary-condition": [
|
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"allowConstantLoopConditions": true
|
|
|
|
}
|
|
|
|
],
|
2022-02-19 22:08:50 +01:00
|
|
|
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/adjacent-overload-signatures": "error",
|
|
|
|
"@typescript-eslint/array-type": [
|
|
|
|
"error",
|
|
|
|
{ "default": "array-simple" }
|
|
|
|
],
|
2024-09-17 23:43:56 +02:00
|
|
|
"@typescript-eslint/no-unsafe-function-type": "error",
|
|
|
|
"@typescript-eslint/no-wrapper-object-types": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/consistent-type-definitions": [
|
|
|
|
"error",
|
|
|
|
"interface"
|
|
|
|
],
|
2023-07-18 22:31:59 +02:00
|
|
|
"no-duplicate-imports": "off",
|
2022-08-31 13:56:16 +02:00
|
|
|
"@typescript-eslint/consistent-type-imports": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/explicit-function-return-type": [
|
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"allowExpressions": true,
|
|
|
|
"allowHigherOrderFunctions": true,
|
|
|
|
"allowTypedFunctionExpressions": true,
|
|
|
|
"allowDirectConstAssertionInArrowFunctions": true
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"@typescript-eslint/method-signature-style": "error",
|
2024-09-25 16:22:08 +02:00
|
|
|
"@typescript-eslint/unbound-method": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/naming-convention": [
|
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"selector": "variableLike",
|
|
|
|
"leadingUnderscore": "allow",
|
|
|
|
"trailingUnderscore": "allow",
|
|
|
|
"format": ["camelCase", "PascalCase", "UPPER_CASE"]
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"@typescript-eslint/no-base-to-string": "error",
|
2024-09-25 17:52:28 +02:00
|
|
|
"@typescript-eslint/no-deprecated": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/no-dynamic-delete": "error",
|
|
|
|
"@typescript-eslint/no-extra-non-null-assertion": "error",
|
2024-09-25 16:44:52 +02:00
|
|
|
"@typescript-eslint/no-redundant-type-constituents": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/no-extraneous-class": [
|
|
|
|
"error",
|
|
|
|
{ "allowWithDecorator": true }
|
|
|
|
],
|
|
|
|
"@typescript-eslint/no-floating-promises": "error",
|
|
|
|
"@typescript-eslint/no-for-in-array": "error",
|
|
|
|
"@typescript-eslint/no-invalid-void-type": "error",
|
|
|
|
"@typescript-eslint/no-misused-new": "error",
|
|
|
|
"@typescript-eslint/no-non-null-asserted-optional-chain": "error",
|
|
|
|
"@typescript-eslint/no-non-null-assertion": "error",
|
|
|
|
"@typescript-eslint/no-this-alias": [
|
|
|
|
"error",
|
|
|
|
{ "allowDestructuring": true }
|
|
|
|
],
|
|
|
|
"@typescript-eslint/no-unnecessary-boolean-literal-compare": "error",
|
|
|
|
"@typescript-eslint/no-unnecessary-type-assertion": "error",
|
2024-02-16 20:02:41 +01:00
|
|
|
"@typescript-eslint/no-require-imports": "error",
|
2023-11-14 12:52:10 +01:00
|
|
|
"@typescript-eslint/no-unsafe-unary-minus": "error",
|
2024-09-25 16:30:23 +02:00
|
|
|
"@typescript-eslint/no-unsafe-declaration-merging": "error",
|
2024-02-08 22:46:43 +01:00
|
|
|
"@typescript-eslint/no-array-delete": "error",
|
2024-02-08 22:56:43 +01:00
|
|
|
"@typescript-eslint/prefer-as-const": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/prefer-function-type": "error",
|
2024-02-08 22:47:38 +01:00
|
|
|
"@typescript-eslint/prefer-find": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/prefer-includes": "error",
|
|
|
|
"@typescript-eslint/prefer-nullish-coalescing": [
|
|
|
|
"error",
|
|
|
|
{
|
2023-07-18 23:06:31 +02:00
|
|
|
"ignoreTernaryTests": true,
|
2022-02-19 16:05:21 +01:00
|
|
|
"ignoreConditionalTests": false,
|
|
|
|
"ignoreMixedLogicalExpressions": false
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"@typescript-eslint/prefer-readonly": "error",
|
|
|
|
"@typescript-eslint/prefer-reduce-type-parameter": "error",
|
2024-05-21 19:39:49 +02:00
|
|
|
"@typescript-eslint/prefer-return-this-type": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/promise-function-async": "error",
|
2024-02-08 22:53:25 +01:00
|
|
|
"prefer-promise-reject-errors": "off",
|
|
|
|
"@typescript-eslint/prefer-promise-reject-errors": "error",
|
2022-02-19 16:05:21 +01:00
|
|
|
"@typescript-eslint/require-array-sort-compare": [
|
|
|
|
"error",
|
|
|
|
{ "ignoreStringArrays": true }
|
|
|
|
],
|
|
|
|
"@typescript-eslint/restrict-plus-operands": [
|
|
|
|
"error",
|
2023-07-14 23:19:09 +02:00
|
|
|
{ "skipCompoundAssignments": true }
|
2022-02-19 16:05:21 +01:00
|
|
|
],
|
|
|
|
"@typescript-eslint/restrict-template-expressions": [
|
|
|
|
"error",
|
|
|
|
{ "allowNumber": true }
|
|
|
|
],
|
|
|
|
"@typescript-eslint/strict-boolean-expressions": [
|
|
|
|
"error",
|
|
|
|
{
|
|
|
|
"allowString": false,
|
|
|
|
"allowNumber": false,
|
|
|
|
"allowNullableObject": false,
|
|
|
|
"allowNullableBoolean": false,
|
|
|
|
"allowNullableString": false,
|
|
|
|
"allowNullableNumber": false,
|
|
|
|
"allowAny": false
|
|
|
|
}
|
2024-09-17 23:43:56 +02:00
|
|
|
]
|
2022-02-19 16:05:21 +01:00
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|