From 2a4d512f0480b1651f351311c7eb5df1d8499333 Mon Sep 17 00:00:00 2001 From: Jimmy Guzman <30631540+jimmy-guzman@users.noreply.github.com> Date: Mon, 8 Apr 2024 17:20:47 -0500 Subject: [PATCH] =?UTF-8?q?feat:=20=E2=9C=A8=20use=20`typescript-eslint`?= =?UTF-8?q?=20shared=20config's=20name=20(#3)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 5 - package.json | 13 +- pnpm-lock.yaml | 96 +- src/__snapshots__/factory.spec.ts.snap | 23399 ------------ .../__snapshots__/typescript.spec.ts.snap | 31789 ++++++++++++++++ src/configs/typescript.spec.ts | 9 + src/configs/typescript.ts | 27 +- src/factory.spec.ts | 9 +- vitest.config.ts | 3 + 9 files changed, 31874 insertions(+), 23476 deletions(-) create mode 100644 src/configs/__snapshots__/typescript.spec.ts.snap create mode 100644 src/configs/typescript.spec.ts diff --git a/README.md b/README.md index 67c4729..e69c8e3 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,6 @@ Then if you want a simple configuration: ```js // eslint.config.mjs -// @ts-check import jimmyDotCodes from "@jimmy.codes/eslint-config"; export default jimmyDotCodes(); @@ -45,7 +44,6 @@ This package contains rules that can be enabled or disabled as follows: ```js // eslint.config.mjs -// @ts-check import jimmyDotCodes from "@jimmy.codes/eslint-config"; export default jimmyDotCodes({ @@ -73,7 +71,6 @@ You can also change the project location which can be helpful for monorepos: ```js // eslint.config.mjs -// @ts-check import jimmyDotCodes from "@jimmy.codes/eslint-config"; export default jimmyDotCodes({ @@ -89,7 +86,6 @@ By default [vitest](https://vitest.dev) is used as the testing framework but you ```js // eslint.config.mjs -// @ts-check import jimmyDotCodes from "@jimmy.codes/eslint-config"; export default jimmyDotCodes({ @@ -106,7 +102,6 @@ You can also extend or override the configuration: ```js // eslint.config.mjs -// @ts-check import jimmyDotCodes from "@jimmy.codes/eslint-config"; export default jimmyDotCodes({ diff --git a/package.json b/package.json index 716f965..7e4d82d 100644 --- a/package.json +++ b/package.json @@ -34,8 +34,8 @@ "build": "pkgroll --minify", "coverage": "vitest run --coverage", "dev": "pkgroll --watch", - "docs:view": "npx @eslint/config-inspector --open=false", "docs:build": "npx @eslint/config-inspector build", + "docs:view": "npx @eslint/config-inspector --open=false", "format": "prettier --check --cache .", "format:fix": "prettier --write --cache .", "lint": "eslint .", @@ -48,7 +48,7 @@ "prettier": "@jimmy.codes/prettier-config", "dependencies": { "@eslint/js": "^8.57.0", - "@typescript-eslint/utils": "^7.5.0", + "@typescript-eslint/utils": "^7.6.0", "eslint-config-prettier": "^9.1.0", "eslint-import-resolver-typescript": "^3.6.1", "eslint-plugin-import-x": "0.5.0", @@ -62,7 +62,7 @@ "eslint-plugin-simple-import-sort": "^12.0.0", "eslint-plugin-testing-library": "^6.2.0", "globals": "^15.0.0", - "typescript-eslint": "^7.5.0" + "typescript-eslint": "^7.6.0" }, "devDependencies": { "@commitlint/config-conventional": "19.1.0", @@ -100,6 +100,13 @@ "publishConfig": { "access": "public" }, + "pnpm": { + "peerDependencyRules": { + "ignoreMissing": [ + "eslint-plugin-import" + ] + } + }, "gitzy": { "useCommitlintConfig": true } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index b3fdaa8..cebdaf7 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -9,8 +9,8 @@ dependencies: specifier: ^8.57.0 version: 8.57.0 '@typescript-eslint/utils': - specifier: ^7.5.0 - version: 7.5.0(eslint@8.57.0)(typescript@5.4.4) + specifier: ^7.6.0 + version: 7.6.0(eslint@8.57.0)(typescript@5.4.4) eslint-config-prettier: specifier: ^9.1.0 version: 9.1.0(eslint@8.57.0) @@ -51,8 +51,8 @@ dependencies: specifier: ^15.0.0 version: 15.0.0 typescript-eslint: - specifier: ^7.5.0 - version: 7.5.0(eslint@8.57.0)(typescript@5.4.4) + specifier: ^7.6.0 + version: 7.6.0(eslint@8.57.0)(typescript@5.4.4) devDependencies: '@commitlint/config-conventional': @@ -1284,8 +1284,8 @@ packages: resolution: {integrity: sha512-I8EUhyrgfLrcTkzV3TSsGyl1tSuPrEDzr0yd5m90UgNxQkyDXULk3b6MlQqTCpZpNtWe1K0hzclnZkTcLBe2UQ==} dev: false - /@typescript-eslint/eslint-plugin@7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.4): - resolution: {integrity: sha512-HpqNTH8Du34nLxbKgVMGljZMG0rJd2O9ecvr2QLYp+7512ty1j42KnsFwspPXg1Vh8an9YImf6CokUBltisZFQ==} + /@typescript-eslint/eslint-plugin@7.6.0(@typescript-eslint/parser@7.6.0)(eslint@8.57.0)(typescript@5.4.4): + resolution: {integrity: sha512-gKmTNwZnblUdnTIJu3e9kmeRRzV2j1a/LUO27KNNAnIC5zjy1aSvXSRp4rVNlmAoHlQ7HzX42NbKpcSr4jF80A==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: '@typescript-eslint/parser': ^7.0.0 @@ -1296,11 +1296,11 @@ packages: optional: true dependencies: '@eslint-community/regexpp': 4.10.0 - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.4) - '@typescript-eslint/scope-manager': 7.5.0 - '@typescript-eslint/type-utils': 7.5.0(eslint@8.57.0)(typescript@5.4.4) - '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.4.4) - '@typescript-eslint/visitor-keys': 7.5.0 + '@typescript-eslint/parser': 7.6.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/scope-manager': 7.6.0 + '@typescript-eslint/type-utils': 7.6.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/utils': 7.6.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/visitor-keys': 7.6.0 debug: 4.3.4 eslint: 8.57.0 graphemer: 1.4.0 @@ -1313,8 +1313,8 @@ packages: - supports-color dev: false - /@typescript-eslint/parser@7.5.0(eslint@8.57.0)(typescript@5.4.4): - resolution: {integrity: sha512-cj+XGhNujfD2/wzR1tabNsidnYRaFfEkcULdcIyVBYcXjBvBKOes+mpMBP7hMpOyk+gBcfXsrg4NBGAStQyxjQ==} + /@typescript-eslint/parser@7.6.0(eslint@8.57.0)(typescript@5.4.4): + resolution: {integrity: sha512-usPMPHcwX3ZoPWnBnhhorc14NJw9J4HpSXQX4urF2TPKG0au0XhJoZyX62fmvdHONUkmyUe74Hzm1//XA+BoYg==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: eslint: ^8.56.0 @@ -1323,10 +1323,10 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/scope-manager': 7.5.0 - '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.4) - '@typescript-eslint/visitor-keys': 7.5.0 + '@typescript-eslint/scope-manager': 7.6.0 + '@typescript-eslint/types': 7.6.0 + '@typescript-eslint/typescript-estree': 7.6.0(typescript@5.4.4) + '@typescript-eslint/visitor-keys': 7.6.0 debug: 4.3.4 eslint: 8.57.0 typescript: 5.4.4 @@ -1350,16 +1350,16 @@ packages: '@typescript-eslint/visitor-keys': 6.21.0 dev: false - /@typescript-eslint/scope-manager@7.5.0: - resolution: {integrity: sha512-Z1r7uJY0MDeUlql9XJ6kRVgk/sP11sr3HKXn268HZyqL7i4cEfrdFuSSY/0tUqT37l5zT0tJOsuDP16kio85iA==} + /@typescript-eslint/scope-manager@7.6.0: + resolution: {integrity: sha512-ngttyfExA5PsHSx0rdFgnADMYQi+Zkeiv4/ZxGYUWd0nLs63Ha0ksmp8VMxAIC0wtCFxMos7Lt3PszJssG/E6w==} engines: {node: ^18.18.0 || >=20.0.0} dependencies: - '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/visitor-keys': 7.5.0 + '@typescript-eslint/types': 7.6.0 + '@typescript-eslint/visitor-keys': 7.6.0 dev: false - /@typescript-eslint/type-utils@7.5.0(eslint@8.57.0)(typescript@5.4.4): - resolution: {integrity: sha512-A021Rj33+G8mx2Dqh0nMO9GyjjIBK3MqgVgZ2qlKf6CJy51wY/lkkFqq3TqqnH34XyAHUkq27IjlUkWlQRpLHw==} + /@typescript-eslint/type-utils@7.6.0(eslint@8.57.0)(typescript@5.4.4): + resolution: {integrity: sha512-NxAfqAPNLG6LTmy7uZgpK8KcuiS2NZD/HlThPXQRGwz6u7MDBWRVliEEl1Gj6U7++kVJTpehkhZzCJLMK66Scw==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: eslint: ^8.56.0 @@ -1368,8 +1368,8 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.4) - '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/typescript-estree': 7.6.0(typescript@5.4.4) + '@typescript-eslint/utils': 7.6.0(eslint@8.57.0)(typescript@5.4.4) debug: 4.3.4 eslint: 8.57.0 ts-api-utils: 1.3.0(typescript@5.4.4) @@ -1388,8 +1388,8 @@ packages: engines: {node: ^16.0.0 || >=18.0.0} dev: false - /@typescript-eslint/types@7.5.0: - resolution: {integrity: sha512-tv5B4IHeAdhR7uS4+bf8Ov3k793VEVHd45viRRkehIUZxm0WF82VPiLgHzA/Xl4TGPg1ZD49vfxBKFPecD5/mg==} + /@typescript-eslint/types@7.6.0: + resolution: {integrity: sha512-h02rYQn8J+MureCvHVVzhl69/GAfQGPQZmOMjG1KfCl7o3HtMSlPaPUAPu6lLctXI5ySRGIYk94clD/AUMCUgQ==} engines: {node: ^18.18.0 || >=20.0.0} dev: false @@ -1436,8 +1436,8 @@ packages: - supports-color dev: false - /@typescript-eslint/typescript-estree@7.5.0(typescript@5.4.4): - resolution: {integrity: sha512-YklQQfe0Rv2PZEueLTUffiQGKQneiIEKKnfIqPIOxgM9lKSZFCjT5Ad4VqRKj/U4+kQE3fa8YQpskViL7WjdPQ==} + /@typescript-eslint/typescript-estree@7.6.0(typescript@5.4.4): + resolution: {integrity: sha512-+7Y/GP9VuYibecrCQWSKgl3GvUM5cILRttpWtnAu8GNL9j11e4tbuGZmZjJ8ejnKYyBRb2ddGQ3rEFCq3QjMJw==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: typescript: '*' @@ -1445,12 +1445,12 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/visitor-keys': 7.5.0 + '@typescript-eslint/types': 7.6.0 + '@typescript-eslint/visitor-keys': 7.6.0 debug: 4.3.4 globby: 11.1.0 is-glob: 4.0.3 - minimatch: 9.0.3 + minimatch: 9.0.4 semver: 7.6.0 ts-api-utils: 1.3.0(typescript@5.4.4) typescript: 5.4.4 @@ -1497,8 +1497,8 @@ packages: - typescript dev: false - /@typescript-eslint/utils@7.5.0(eslint@8.57.0)(typescript@5.4.4): - resolution: {integrity: sha512-3vZl9u0R+/FLQcpy2EHyRGNqAS/ofJ3Ji8aebilfJe+fobK8+LbIFmrHciLVDxjDoONmufDcnVSF38KwMEOjzw==} + /@typescript-eslint/utils@7.6.0(eslint@8.57.0)(typescript@5.4.4): + resolution: {integrity: sha512-x54gaSsRRI+Nwz59TXpCsr6harB98qjXYzsRxGqvA5Ue3kQH+FxS7FYU81g/omn22ML2pZJkisy6Q+ElK8pBCA==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: eslint: ^8.56.0 @@ -1506,9 +1506,9 @@ packages: '@eslint-community/eslint-utils': 4.4.0(eslint@8.57.0) '@types/json-schema': 7.0.15 '@types/semver': 7.5.8 - '@typescript-eslint/scope-manager': 7.5.0 - '@typescript-eslint/types': 7.5.0 - '@typescript-eslint/typescript-estree': 7.5.0(typescript@5.4.4) + '@typescript-eslint/scope-manager': 7.6.0 + '@typescript-eslint/types': 7.6.0 + '@typescript-eslint/typescript-estree': 7.6.0(typescript@5.4.4) eslint: 8.57.0 semver: 7.6.0 transitivePeerDependencies: @@ -1532,11 +1532,11 @@ packages: eslint-visitor-keys: 3.4.3 dev: false - /@typescript-eslint/visitor-keys@7.5.0: - resolution: {integrity: sha512-mcuHM/QircmA6O7fy6nn2w/3ditQkj+SgtOc8DW3uQ10Yfj42amm2i+6F2K4YAOPNNTmE6iM1ynM6lrSwdendA==} + /@typescript-eslint/visitor-keys@7.6.0: + resolution: {integrity: sha512-4eLB7t+LlNUmXzfOu1VAIAdkjbu5xNSerURS9X/S5TUKWFRpXRQZbmtPqgKmYx8bj3J0irtQXSiWAOY82v+cgw==} engines: {node: ^18.18.0 || >=20.0.0} dependencies: - '@typescript-eslint/types': 7.5.0 + '@typescript-eslint/types': 7.6.0 eslint-visitor-keys: 3.4.3 dev: false @@ -2633,6 +2633,9 @@ packages: peerDependencies: eslint: '*' eslint-plugin-import: '*' + peerDependenciesMeta: + eslint-plugin-import: + optional: true dependencies: debug: 4.3.4 enhanced-resolve: 5.16.0 @@ -2683,7 +2686,7 @@ packages: peerDependencies: eslint: ^8.56.0 || ^9.0.0-0 dependencies: - '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/utils': 7.6.0(eslint@8.57.0)(typescript@5.4.4) debug: 4.3.4 doctrine: 3.0.0 eslint: 8.57.0 @@ -4234,7 +4237,6 @@ packages: engines: {node: '>=16 || 14 >=14.17'} dependencies: brace-expansion: 2.0.1 - dev: true /minimist@1.2.8: resolution: {integrity: sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA==} @@ -5619,8 +5621,8 @@ packages: possible-typed-array-names: 1.0.0 dev: false - /typescript-eslint@7.5.0(eslint@8.57.0)(typescript@5.4.4): - resolution: {integrity: sha512-eKhF39LRi2xYvvXh3h3S+mCxC01dZTIZBlka25o39i81VeQG+OZyfC4i2GEDspNclMRdXkg9uGhmvWMhjph2XQ==} + /typescript-eslint@7.6.0(eslint@8.57.0)(typescript@5.4.4): + resolution: {integrity: sha512-LY6vH6F1l5jpGqRtU+uK4+mOecIb4Cd4kaz1hAiJrgnNiHUA8wiw8BkJyYS+MRLM69F1QuSKwtGlQqnGl1Rc6w==} engines: {node: ^18.18.0 || >=20.0.0} peerDependencies: eslint: ^8.56.0 @@ -5629,9 +5631,9 @@ packages: typescript: optional: true dependencies: - '@typescript-eslint/eslint-plugin': 7.5.0(@typescript-eslint/parser@7.5.0)(eslint@8.57.0)(typescript@5.4.4) - '@typescript-eslint/parser': 7.5.0(eslint@8.57.0)(typescript@5.4.4) - '@typescript-eslint/utils': 7.5.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/eslint-plugin': 7.6.0(@typescript-eslint/parser@7.6.0)(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/parser': 7.6.0(eslint@8.57.0)(typescript@5.4.4) + '@typescript-eslint/utils': 7.6.0(eslint@8.57.0)(typescript@5.4.4) eslint: 8.57.0 typescript: 5.4.4 transitivePeerDependencies: diff --git a/src/__snapshots__/factory.spec.ts.snap b/src/__snapshots__/factory.spec.ts.snap index b807440..ec0d824 100644 --- a/src/__snapshots__/factory.spec.ts.snap +++ b/src/__snapshots__/factory.spec.ts.snap @@ -24217,23405 +24217,6 @@ exports[`jimmyDotCodes > should create configuration w/ react 1`] = ` ] `; -exports[`jimmyDotCodes > should create configuration w/ typescript 1`] = ` -[ - { - "name": "jimmy.codes/base", - "rules": { - "arrow-body-style": [ - "error", - "always", - ], - "constructor-super": "error", - "curly": "error", - "for-direction": "error", - "getter-return": "error", - "no-async-promise-executor": "error", - "no-case-declarations": "error", - "no-class-assign": "error", - "no-compare-neg-zero": "error", - "no-cond-assign": "error", - "no-const-assign": "error", - "no-constant-condition": "error", - "no-control-regex": "error", - "no-debugger": "error", - "no-delete-var": "error", - "no-dupe-args": "error", - "no-dupe-class-members": "error", - "no-dupe-else-if": "error", - "no-dupe-keys": "error", - "no-duplicate-case": "error", - "no-empty": "error", - "no-empty-character-class": "error", - "no-empty-pattern": "error", - "no-ex-assign": "error", - "no-extra-boolean-cast": "error", - "no-extra-semi": "error", - "no-fallthrough": "error", - "no-func-assign": "error", - "no-global-assign": "error", - "no-import-assign": "error", - "no-inner-declarations": "error", - "no-invalid-regexp": "error", - "no-irregular-whitespace": "error", - "no-loss-of-precision": "error", - "no-misleading-character-class": "error", - "no-mixed-spaces-and-tabs": "error", - "no-new-symbol": "error", - "no-nonoctal-decimal-escape": "error", - "no-obj-calls": "error", - "no-octal": "error", - "no-prototype-builtins": "error", - "no-redeclare": "error", - "no-regex-spaces": "error", - "no-self-assign": "error", - "no-setter-return": "error", - "no-shadow-restricted-names": "error", - "no-sparse-arrays": "error", - "no-this-before-super": "error", - "no-undef": "error", - "no-unexpected-multiline": "error", - "no-unreachable": "error", - "no-unsafe-finally": "error", - "no-unsafe-negation": "error", - "no-unsafe-optional-chaining": "error", - "no-unused-labels": "error", - "no-unused-vars": "error", - "no-useless-backreference": "error", - "no-useless-catch": "error", - "no-useless-escape": "error", - "no-with": "error", - "object-shorthand": "error", - "prefer-arrow-callback": "error", - "require-yield": "error", - "use-isnan": "error", - "valid-typeof": "error", - }, - }, - { - "name": "jimmy.codes/imports", - "plugins": { - "import-x": { - "configs": { - "electron": { - "settings": { - "import-x/core-modules": [ - "electron", - ], - }, - }, - "errors": { - "plugins": [ - "import-x", - ], - "rules": { - "import-x/default": 2, - "import-x/export": 2, - "import-x/named": 2, - "import-x/namespace": 2, - "import-x/no-unresolved": 2, - }, - }, - "react": { - "parserOptions": { - "ecmaFeatures": { - "jsx": true, - }, - }, - "settings": { - "import-x/extensions": [ - ".js", - ".jsx", - ], - }, - }, - "react-native": { - "settings": { - "import-x/resolver": { - "node": { - "extensions": [ - ".js", - ".web.js", - ".ios.js", - ".android.js", - ], - }, - }, - }, - }, - "recommended": { - "parserOptions": { - "ecmaVersion": 2018, - "sourceType": "module", - }, - "plugins": [ - "import-x", - ], - "rules": { - "import-x/default": "error", - "import-x/export": "error", - "import-x/named": "error", - "import-x/namespace": "error", - "import-x/no-duplicates": "warn", - "import-x/no-named-as-default": "warn", - "import-x/no-named-as-default-member": "warn", - "import-x/no-unresolved": "error", - }, - }, - "stage-0": { - "plugins": [ - "import-x", - ], - "rules": { - "import-x/no-deprecated": 1, - }, - }, - "typescript": { - "rules": { - "import-x/named": "off", - }, - "settings": { - "import-x/extensions": [ - ".ts", - ".tsx", - ".js", - ".jsx", - ], - "import-x/external-module-folders": [ - "node_modules", - "node_modules/@types", - ], - "import-x/parsers": { - "@typescript-eslint/parser": [ - ".ts", - ".tsx", - ".cts", - ".mts", - ], - }, - "import-x/resolver": { - "node": { - "extensions": [ - ".ts", - ".tsx", - ".js", - ".jsx", - ], - }, - }, - }, - }, - "warnings": { - "plugins": [ - "import-x", - ], - "rules": { - "import-x/no-duplicates": 1, - "import-x/no-named-as-default": 1, - "import-x/no-named-as-default-member": 1, - }, - }, - }, - "rules": { - "consistent-type-specifier-style": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Enforce or ban the use of inline type-only markers for named imports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/consistent-type-specifier-style.md", - }, - "fixable": "code", - "messages": { - "inline": "Prefer using inline {{kind}} specifiers instead of a top-level {{kind}}-only import.", - "topLevel": "Prefer using a top-level {{kind}}-only import instead of inline {{kind}} specifiers.", - }, - "schema": [ - { - "default": "prefer-inline", - "enum": [ - "prefer-inline", - "prefer-top-level", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "default": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Ensure a default export is present, given a default import.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/default.md", - }, - "messages": { - "noDefaultExport": "No default export found in imported module "{{module}}".", - }, - "schema": [], - "type": "problem", - }, - }, - "dynamic-import-chunkname": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Enforce a leading comment with the webpackChunkName for dynamic imports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/dynamic-import-chunkname.md", - }, - "messages": { - "blockComment": "dynamic imports require a /* foo */ style comment, not a // foo comment", - "chunknameFormat": "dynamic imports require a leading comment in the form /*{{format}}*/", - "leadingComment": "dynamic imports require a leading comment with the webpack chunkname", - "paddedSpaces": "dynamic imports require a block comment padded with spaces - /* foo */", - "webpackComment": "dynamic imports require a "webpack" comment with valid syntax", - }, - "schema": [ - { - "properties": { - "allowEmpty": { - "type": "boolean", - }, - "importFunctions": { - "items": { - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - "webpackChunknameFormat": { - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "export": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Helpful warnings", - "description": "Forbid any invalid exports, i.e. re-export of the same name.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/export.md", - }, - "messages": { - "multiDefault": "Multiple default exports.", - "multiNamed": "Multiple exports of name '{{name}}'.", - "noNamed": "No named exports found in module '{{module}}'.", - }, - "schema": [], - "type": "problem", - }, - }, - "exports-last": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Ensure all exports appear after other statements.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/exports-last.md", - }, - "messages": { - "end": "Export statements should appear at the end of the file", - }, - "schema": [], - "type": "suggestion", - }, - }, - "extensions": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Ensure consistent use of file extension within the import path.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/extensions.md", - }, - "messages": { - "missing": "Missing file extension {{extension}}for "{{importPath}}"", - "unexpected": "Unexpected use of file extension "{{extension}}" for "{{importPath}}"", - }, - "schema": { - "anyOf": [ - { - "additionalItems": false, - "items": [ - { - "enum": [ - "always", - "ignorePackages", - "never", - ], - "type": "string", - }, - ], - "type": "array", - }, - { - "additionalItems": false, - "items": [ - { - "enum": [ - "always", - "ignorePackages", - "never", - ], - "type": "string", - }, - { - "properties": { - "ignorePackages": { - "type": "boolean", - }, - "pattern": { - "patternProperties": { - ".*": { - "enum": [ - "always", - "ignorePackages", - "never", - ], - "type": "string", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "array", - }, - { - "additionalItems": false, - "items": [ - { - "properties": { - "ignorePackages": { - "type": "boolean", - }, - "pattern": { - "patternProperties": { - ".*": { - "enum": [ - "always", - "ignorePackages", - "never", - ], - "type": "string", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "array", - }, - { - "additionalItems": false, - "items": [ - { - "patternProperties": { - ".*": { - "enum": [ - "always", - "ignorePackages", - "never", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "array", - }, - { - "additionalItems": false, - "items": [ - { - "enum": [ - "always", - "ignorePackages", - "never", - ], - "type": "string", - }, - { - "patternProperties": { - ".*": { - "enum": [ - "always", - "ignorePackages", - "never", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "array", - }, - ], - }, - "type": "suggestion", - }, - }, - "first": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Ensure all imports appear before other statements.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/first.md", - }, - "fixable": "code", - "messages": { - "absolute": "Absolute imports should come before relative imports.", - "order": "Import in body of module; reorder to top.", - }, - "schema": [ - { - "enum": [ - "absolute-first", - "disable-absolute-first", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "group-exports": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Prefer named exports to be grouped together in a single export declaration.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/group-exports.md", - }, - "messages": { - "AssignmentExpression": "Multiple CommonJS exports; consolidate all exports into a single assignment to \`module.exports\`", - "ExportNamedDeclaration": "Multiple named export declarations; consolidate all named exports into a single export declaration", - }, - "schema": [], - "type": "suggestion", - }, - }, - "imports-first": { - "create": [Function], - "defaultOptions": [], - "meta": { - "deprecated": true, - "docs": { - "category": "Style guide", - "description": "Replaced by \`import-x/first\`.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/7b25c1cb95ee18acc1531002fd343e1e6031f9ed/docs/rules/imports-first.md", - }, - "fixable": "code", - "messages": { - "absolute": "Absolute imports should come before relative imports.", - "order": "Import in body of module; reorder to top.", - }, - "schema": [ - { - "enum": [ - "absolute-first", - "disable-absolute-first", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "max-dependencies": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Enforce the maximum number of dependencies a module can have.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/max-dependencies.md", - }, - "messages": { - "max": "Maximum number of dependencies ({{max}}) exceeded.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreTypeImports": { - "type": "boolean", - }, - "max": { - "type": "number", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "named": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Ensure named imports correspond to a named export in the remote file.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/named.md", - }, - "messages": { - "notFound": "{{name}} not found in '{{path}}'", - "notFoundDeep": "{{name}} not found via {{deepPath}}", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "commonjs": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "namespace": { - "create": [Function], - "defaultOptions": [ - { - "allowComputed": false, - }, - ], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Ensure imported namespaces contain dereferenced properties as they are dereferenced.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/namespace.md", - }, - "messages": { - "computedReference": "Unable to validate computed reference to imported namespace '{{namespace}}'.", - "namespaceMember": "Assignment to member of namespace '{{namespace}}'.", - "noNamesFound": "No exported names found in module '{{module}}'.", - "notFoundInNamespace": "'{{name}}' not found in {{depth}}imported namespace '{{namepath}}'.", - "topLevelNames": "Only destructure top-level names.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowComputed": { - "default": false, - "description": "If \`false\`, will report computed (and thus, un-lintable) references to namespace members.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "newline-after-import": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Enforce a newline after import statements.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/newline-after-import.md", - }, - "fixable": "whitespace", - "messages": { - "newline": "Expected {{count}} empty line{{lineSuffix}} after {{type}} statement not followed by another {{type}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "considerComments": { - "type": "boolean", - }, - "count": { - "minimum": 1, - "type": "integer", - }, - "exactCount": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "no-absolute-path": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid import of modules using absolute paths.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-absolute-path.md", - }, - "fixable": "code", - "messages": { - "absolute": "Do not import modules using an absolute path", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "amd": { - "type": "boolean", - }, - "commonjs": { - "type": "boolean", - }, - "esmodule": { - "type": "boolean", - }, - "ignore": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-amd": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Module systems", - "description": "Forbid AMD \`require\` and \`define\` calls.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-amd.md", - }, - "messages": { - "amd": "Expected imports instead of AMD {{type}}().", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-anonymous-default-export": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Forbid anonymous values as default exports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-anonymous-default-export.md", - }, - "messages": { - "anonymous": "Unexpected default export of anonymous {{type}}", - "assign": "Assign {{type}} to a variable before exporting as module default", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAnonymousClass": { - "description": "If \`false\`, will report default export of an anonymous class", - "type": "boolean", - }, - "allowAnonymousFunction": { - "description": "If \`false\`, will report default export of an anonymous function", - "type": "boolean", - }, - "allowArray": { - "description": "If \`false\`, will report default export of an array", - "type": "boolean", - }, - "allowArrowFunction": { - "description": "If \`false\`, will report default export of an arrow function", - "type": "boolean", - }, - "allowCallExpression": { - "description": "If \`false\`, will report default export of a function call", - "type": "boolean", - }, - "allowLiteral": { - "description": "If \`false\`, will report default export of a literal", - "type": "boolean", - }, - "allowNew": { - "description": "If \`false\`, will report default export of a class instantiation", - "type": "boolean", - }, - "allowObject": { - "description": "If \`false\`, will report default export of an object expression", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-commonjs": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Module systems", - "description": "Forbid CommonJS \`require\` calls and \`module.exports\` or \`exports.*\`.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-commonjs.md", - }, - "messages": { - "export": "Expected "export" or "export default"", - "import": "Expected "import" instead of "require()"", - }, - "schema": { - "anyOf": [ - { - "additionalItems": false, - "items": [ - { - "enum": [ - "allow-primitive-modules", - ], - "type": "string", - }, - ], - "type": "array", - }, - { - "additionalItems": false, - "items": [ - { - "additionalProperties": false, - "properties": { - "allowConditionalRequire": { - "type": "boolean", - }, - "allowPrimitiveModules": { - "type": "boolean", - }, - "allowRequire": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "array", - }, - ], - }, - "type": "suggestion", - }, - }, - "no-cycle": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid a module from importing a module with a dependency path back to itself.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-cycle.md", - }, - "messages": { - "cycle": "Dependency cycle {{source}}", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowUnsafeDynamicCyclicDependency": { - "default": false, - "description": "Allow cyclic dependency if there is at least one dynamic import in the chain", - "type": "boolean", - }, - "amd": { - "type": "boolean", - }, - "commonjs": { - "type": "boolean", - }, - "esmodule": { - "type": "boolean", - }, - "ignore": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - "ignoreExternal": { - "default": false, - "description": "ignore external modules", - "type": "boolean", - }, - "maxDepth": { - "anyOf": [ - { - "description": "maximum dependency depth to traverse", - "minimum": 1, - "type": "integer", - }, - { - "enum": [ - "∞", - ], - "type": "string", - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-default-export": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Forbid default exports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-default-export.md", - }, - "messages": { - "noAliasDefault": "Do not alias \`{{local}}\` as \`default\`. Just export \`{{local}}\` itself instead.", - "preferNamed": "Prefer named exports.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-deprecated": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Helpful warnings", - "description": "Forbid imported names marked with \`@deprecated\` documentation tag.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-deprecated.md", - }, - "messages": { - "deprecated": "Deprecated{{description}}", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-duplicates": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Forbid repeated import of the same module in multiple places.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-duplicates.md", - }, - "fixable": "code", - "messages": { - "duplicate": "'{{module}}' imported multiple times.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "considerQueryString": { - "type": "boolean", - }, - "prefer-inline": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-dynamic-require": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid \`require()\` calls with expressions.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-dynamic-require.md", - }, - "messages": { - "import": "Calls to import() should use string literals", - "require": "Calls to require() should use string literals", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "esmodule": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-empty-named-blocks": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Helpful warnings", - "description": "Forbid empty named import blocks.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-empty-named-blocks.md", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "emptyImport": "Remove empty import block", - "emptyNamed": "Unexpected empty named import block", - "unused": "Remove unused import", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-extraneous-dependencies": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Helpful warnings", - "description": "Forbid the use of extraneous packages.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-extraneous-dependencies.md", - }, - "messages": { - "devDep": "'{{packageName}}' should be listed in the project's dependencies, not devDependencies.", - "missing": "'{{packageName}}' should be listed in the project's dependencies. Run 'npm i -S {{packageName}}' to add it", - "optDep": "'{{packageName}}' should be listed in the project's dependencies, not optionalDependencies.", - "pkgNotFound": "The package.json file could not be found.", - "pkgUnparsable": "The package.json file could not be parsed: {{error}}", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "bundledDependencies": { - "type": [ - "boolean", - "array", - ], - }, - "devDependencies": { - "type": [ - "boolean", - "array", - ], - }, - "includeInternal": { - "type": [ - "boolean", - ], - }, - "includeTypes": { - "type": [ - "boolean", - ], - }, - "optionalDependencies": { - "type": [ - "boolean", - "array", - ], - }, - "packageDir": { - "type": [ - "string", - "array", - ], - }, - "peerDependencies": { - "type": [ - "boolean", - "array", - ], - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-import-module-exports": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Module systems", - "description": "Forbid import statements with CommonJS module.exports.", - "recommended": true, - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-import-module-exports.md", - }, - "fixable": "code", - "messages": { - "notAllowed": "Cannot use import declarations in modules that export using CommonJS (module.exports = 'foo' or exports.bar = 'hi')", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "exceptions": { - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-internal-modules": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid importing the submodules of other modules.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-internal-modules.md", - }, - "messages": { - "noAllowed": "Reaching to "{{importPath}}" is not allowed.", - }, - "schema": [ - { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "forbid": { - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "suggestion", - }, - }, - "no-mutable-exports": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Helpful warnings", - "description": "Forbid the use of mutable exports with \`var\` or \`let\`.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-mutable-exports.md", - }, - "messages": { - "noMutable": "Exporting mutable '{{kind}}' binding, use 'const' instead.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-named-as-default": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Helpful warnings", - "description": "Forbid use of exported name as identifier of default export.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-named-as-default.md", - }, - "messages": { - "default": "Using exported name '{{name}}' as identifier for default export.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-named-as-default-member": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Helpful warnings", - "description": "Forbid use of exported name as property of default export.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-named-as-default-member.md", - }, - "messages": { - "member": "Caution: \`{{objectName}}\` also has a named export \`{{propName}}\`. Check if you meant to write \`import {{{propName}}} from '{{sourcePath}}'\` instead.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-named-default": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Forbid named default exports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-named-default.md", - }, - "messages": { - "default": "Use default import syntax to import '{{importName}}'.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-named-export": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Forbid named exports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-named-export.md", - }, - "messages": { - "noAllowed": "Named exports are not allowed.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-namespace": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Forbid namespace (a.k.a. "wildcard" \`*\`) imports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-namespace.md", - }, - "fixable": "code", - "messages": { - "noNamespace": "Unexpected namespace import.", - }, - "schema": [ - { - "properties": { - "ignore": { - "items": { - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-nodejs-modules": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Module systems", - "description": "Forbid Node.js builtin modules.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-nodejs-modules.md", - }, - "messages": { - "builtin": "Do not import Node.js builtin module "{{moduleName}}"", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-relative-packages": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid importing packages through relative paths.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-relative-packages.md", - }, - "fixable": "code", - "messages": { - "noAllowed": "Relative import from another package is not allowed. Use \`{{properImport}}\` instead of \`{{importPath}}\`", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "amd": { - "type": "boolean", - }, - "commonjs": { - "type": "boolean", - }, - "esmodule": { - "type": "boolean", - }, - "ignore": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-relative-parent-imports": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid importing modules from parent directories.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-relative-parent-imports.md", - }, - "messages": { - "noAllowed": "Relative imports from parent directories are not allowed. Please either pass what you're importing through at runtime (dependency injection), move \`{{filename}}\` to same directory as \`{{depPath}}\` or consider making \`{{depPath}}\` a package.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "amd": { - "type": "boolean", - }, - "commonjs": { - "type": "boolean", - }, - "esmodule": { - "type": "boolean", - }, - "ignore": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-restricted-paths": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Enforce which files can be imported in a given folder.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-restricted-paths.md", - }, - "messages": { - "glob": "Restricted path exceptions must be glob patterns when \`from\` contains glob patterns", - "mixedGlob": "Restricted path \`from\` must contain either only glob patterns or none", - "path": "Restricted path exceptions must be descendants of the configured \`from\` path for that zone.", - "zone": "Unexpected path "{{importPath}}" imported in restricted zone.{{extra}}", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "basePath": { - "type": "string", - }, - "zones": { - "items": { - "additionalProperties": false, - "properties": { - "except": { - "items": { - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - "from": { - "anyOf": [ - { - "type": "string", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - "message": { - "type": "string", - }, - "target": { - "anyOf": [ - { - "type": "string", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - }, - "type": "object", - }, - "minItems": 1, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-self-import": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid a module from importing itself.", - "recommended": true, - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-self-import.md", - }, - "messages": { - "self": "Module imports itself.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unassigned-import": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Forbid unassigned imports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-unassigned-import.md", - }, - "messages": { - "unassigned": "Imported module should be assigned", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "type": "string", - }, - "type": "array", - }, - "devDependencies": { - "type": [ - "boolean", - "array", - ], - }, - "optionalDependencies": { - "type": [ - "boolean", - "array", - ], - }, - "peerDependencies": { - "type": [ - "boolean", - "array", - ], - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unresolved": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Ensure imports point to a file/module that can be resolved.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-unresolved.md", - }, - "messages": { - "casingMismatch": "Casing of {{module}} does not match the underlying filesystem.", - "unresolved": "Unable to resolve path to module '{{module}}'.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "amd": { - "type": "boolean", - }, - "caseSensitive": { - "default": true, - "type": "boolean", - }, - "caseSensitiveStrict": { - "type": "boolean", - }, - "commonjs": { - "type": "boolean", - }, - "esmodule": { - "type": "boolean", - }, - "ignore": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-unused-modules": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Helpful warnings", - "description": "Forbid modules without exports, or exports without matching import in another module.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-unused-modules.md", - }, - "messages": { - "notFound": "No exports found", - "unused": "exported declaration '{{value}}' not used within other modules", - }, - "schema": [ - { - "anyOf": [ - { - "properties": { - "src": { - "minItems": 1, - "type": "array", - }, - "unusedExports": { - "enum": [ - true, - ], - "type": "boolean", - }, - }, - "required": [ - "unusedExports", - ], - "type": "object", - }, - { - "properties": { - "missingExports": { - "enum": [ - true, - ], - "type": "boolean", - }, - }, - "required": [ - "missingExports", - ], - "type": "object", - }, - ], - "properties": { - "ignoreExports": { - "description": "files/paths for which unused exports will not be reported (e.g module entry points)", - "items": { - "minLength": 1, - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - "missingExports": { - "description": "report modules without any exports", - "type": "boolean", - }, - "src": { - "description": "files/paths to be analyzed (only for unused exports)", - "items": { - "minLength": 1, - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - "unusedExports": { - "description": "report exports without any usage", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-useless-path-segments": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid unnecessary path segments in import and require statements.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-useless-path-segments.md", - }, - "fixable": "code", - "messages": { - "useless": "Useless path segments for "{{importPath}}", should be "{{proposedPath}}"", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "commonjs": { - "type": "boolean", - }, - "noUselessIndex": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-webpack-loader-syntax": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Static analysis", - "description": "Forbid webpack loader syntax in imports.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/no-webpack-loader-syntax.md", - }, - "messages": { - "unexpected": "Unexpected '!' in '{{name}}'. Do not use import syntax to configure webpack loaders.", - }, - "schema": [], - "type": "problem", - }, - }, - "order": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Enforce a convention in module import order.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/order.md", - }, - "fixable": "code", - "messages": { - "error": "{{error}}", - "noLineBetweenGroups": "There should be no empty line between import groups", - "noLineWithinGroup": "There should be no empty line within import group", - "oneLineBetweenGroups": "There should be at least one empty line between import groups", - "order": "{{secondImport}} should occur {{order}} {{firstImport}}", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "alphabetize": { - "additionalProperties": false, - "properties": { - "caseInsensitive": { - "default": false, - "type": "boolean", - }, - "order": { - "default": "ignore", - "enum": [ - "ignore", - "asc", - "desc", - ], - "type": "string", - }, - "orderImportKind": { - "default": "ignore", - "enum": [ - "ignore", - "asc", - "desc", - ], - "type": "string", - }, - }, - "type": "object", - }, - "distinctGroup": { - "default": true, - "type": "boolean", - }, - "groups": { - "type": "array", - }, - "newlines-between": { - "enum": [ - "ignore", - "always", - "always-and-inside-groups", - "never", - ], - "type": "string", - }, - "pathGroups": { - "items": { - "additionalProperties": false, - "properties": { - "group": { - "enum": [ - "builtin", - "external", - "internal", - "unknown", - "parent", - "sibling", - "index", - "object", - "type", - ], - "type": "string", - }, - "pattern": { - "type": "string", - }, - "patternOptions": { - "type": "object", - }, - "position": { - "enum": [ - "after", - "before", - ], - "type": "string", - }, - }, - "required": [ - "pattern", - "group", - ], - "type": "object", - }, - "type": "array", - }, - "pathGroupsExcludedImportTypes": { - "type": "array", - }, - "warnOnUnassignedImports": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-default-export": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Style guide", - "description": "Prefer a default export if module exports a single name or multiple names.", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/prefer-default-export.md", - }, - "messages": { - "any": "Prefer default export to be present on every file that has export.", - "single": "Prefer default export on a file with single export.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "target": { - "default": "single", - "enum": [ - "single", - "any", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "unambiguous": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "category": "Module systems", - "description": "Forbid potentially ambiguous parse goal (\`script\` vs. \`module\`).", - "url": "https://github.com/un-ts/eslint-plugin-import-x/blob/v0.5.0/docs/rules/unambiguous.md", - }, - "messages": { - "module": "This module could be parsed as a valid script.", - }, - "schema": [], - "type": "suggestion", - }, - }, - }, - }, - "node-import": { - "rules": { - "prefer-node-protocol": { - "create": [Function], - "meta": { - "docs": { - "description": "Prefer using the \`node:\` protocol when importing Node.js builtin modules.", - "recommended": true, - "url": "https://github.com/kytta/eslint-plugin-node-import/blob/main/docs/rules/prefer-node-protocol", - }, - "fixable": "code", - "messages": { - "prefer-node-protocol": "Consider using \`node:{{ moduleName }}\` over \`{{ moduleName }}\`.", - }, - "schema": [], - "type": "problem", - }, - }, - }, - }, - "simple-import-sort": { - "meta": { - "name": "eslint-plugin-simple-import-sort", - "version": "12.0.0", - }, - "rules": { - "exports": { - "create": [Function], - "meta": { - "docs": { - "url": "https://github.com/lydell/eslint-plugin-simple-import-sort#sort-order", - }, - "fixable": "code", - "messages": { - "sort": "Run autofix to sort these exports!", - }, - "schema": [], - "type": "layout", - }, - }, - "imports": { - "create": [Function], - "meta": { - "docs": { - "url": "https://github.com/lydell/eslint-plugin-simple-import-sort#sort-order", - }, - "fixable": "code", - "messages": { - "sort": "Run autofix to sort these imports!", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "groups": { - "items": { - "items": { - "type": "string", - }, - "type": "array", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - }, - }, - }, - "rules": { - "import-x/default": "error", - "import-x/export": "error", - "import-x/first": "error", - "import-x/named": "error", - "import-x/namespace": "off", - "import-x/newline-after-import": "error", - "import-x/no-absolute-path": "error", - "import-x/no-duplicates": "warn", - "import-x/no-empty-named-blocks": "error", - "import-x/no-named-as-default": "warn", - "import-x/no-named-as-default-member": "warn", - "import-x/no-self-import": "error", - "import-x/no-unresolved": "error", - "import-x/no-useless-path-segments": "error", - "node-import/prefer-node-protocol": "error", - "simple-import-sort/exports": "error", - "simple-import-sort/imports": "error", - }, - }, - { - "name": "jimmy.codes/imports/typescript", - "rules": { - "import-x/named": "off", - }, - "settings": { - "import-x/extensions": [ - ".ts", - ".tsx", - ".js", - ".jsx", - ], - "import-x/external-module-folders": [ - "node_modules", - "node_modules/@types", - ], - "import-x/parsers": { - "@typescript-eslint/parser": [ - ".ts", - ".tsx", - ".cts", - ".mts", - ], - }, - "import-x/resolver": { - "node": { - "extensions": [ - ".ts", - ".tsx", - ".js", - ".jsx", - ], - }, - "typescript": true, - }, - }, - }, - { - "languageOptions": { - "parser": { - "meta": { - "name": "typescript-eslint/parser", - "version": "7.5.0", - }, - "parseForESLint": [Function], - }, - "sourceType": "module", - }, - "name": "jimmy.codes/typescript", - "plugins": { - "@typescript-eslint": { - "configs": { - "all": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/adjacent-overload-signatures": "error", - "@typescript-eslint/array-type": "error", - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": "error", - "@typescript-eslint/ban-tslint-comment": "error", - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/class-literal-property-style": "error", - "@typescript-eslint/class-methods-use-this": "error", - "@typescript-eslint/consistent-generic-constructors": "error", - "@typescript-eslint/consistent-indexed-object-style": "error", - "@typescript-eslint/consistent-return": "error", - "@typescript-eslint/consistent-type-assertions": "error", - "@typescript-eslint/consistent-type-definitions": "error", - "@typescript-eslint/consistent-type-exports": "error", - "@typescript-eslint/consistent-type-imports": "error", - "@typescript-eslint/default-param-last": "error", - "@typescript-eslint/dot-notation": "error", - "@typescript-eslint/explicit-function-return-type": "error", - "@typescript-eslint/explicit-member-accessibility": "error", - "@typescript-eslint/explicit-module-boundary-types": "error", - "@typescript-eslint/init-declarations": "error", - "@typescript-eslint/max-params": "error", - "@typescript-eslint/member-ordering": "error", - "@typescript-eslint/method-signature-style": "error", - "@typescript-eslint/naming-convention": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-array-delete": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-confusing-non-null-assertion": "error", - "@typescript-eslint/no-confusing-void-expression": "error", - "@typescript-eslint/no-dupe-class-members": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-dynamic-delete": "error", - "@typescript-eslint/no-empty-function": "error", - "@typescript-eslint/no-empty-interface": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-extraneous-class": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-import-type-side-effects": "error", - "@typescript-eslint/no-inferrable-types": "error", - "@typescript-eslint/no-invalid-this": "error", - "@typescript-eslint/no-invalid-void-type": "error", - "@typescript-eslint/no-loop-func": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-magic-numbers": "error", - "@typescript-eslint/no-meaningless-void-operator": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-mixed-enums": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-non-null-assertion": "error", - "@typescript-eslint/no-redeclare": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-require-imports": "error", - "@typescript-eslint/no-restricted-imports": "error", - "@typescript-eslint/no-shadow": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", - "@typescript-eslint/no-unnecessary-condition": "error", - "@typescript-eslint/no-unnecessary-qualifier": "error", - "@typescript-eslint/no-unnecessary-type-arguments": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unsafe-unary-minus": "error", - "@typescript-eslint/no-unused-expressions": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-use-before-define": "error", - "@typescript-eslint/no-useless-constructor": "error", - "@typescript-eslint/no-useless-empty-export": "error", - "@typescript-eslint/no-useless-template-literals": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/non-nullable-type-assertion-style": "error", - "@typescript-eslint/only-throw-error": "error", - "@typescript-eslint/parameter-properties": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/prefer-destructuring": "error", - "@typescript-eslint/prefer-enum-initializers": "error", - "@typescript-eslint/prefer-find": "error", - "@typescript-eslint/prefer-for-of": "error", - "@typescript-eslint/prefer-function-type": "error", - "@typescript-eslint/prefer-includes": "error", - "@typescript-eslint/prefer-literal-enum-member": "error", - "@typescript-eslint/prefer-namespace-keyword": "error", - "@typescript-eslint/prefer-nullish-coalescing": "error", - "@typescript-eslint/prefer-optional-chain": "error", - "@typescript-eslint/prefer-promise-reject-errors": "error", - "@typescript-eslint/prefer-readonly": "error", - "@typescript-eslint/prefer-readonly-parameter-types": "error", - "@typescript-eslint/prefer-reduce-type-parameter": "error", - "@typescript-eslint/prefer-regexp-exec": "error", - "@typescript-eslint/prefer-return-this-type": "error", - "@typescript-eslint/prefer-string-starts-ends-with": "error", - "@typescript-eslint/prefer-ts-expect-error": "error", - "@typescript-eslint/promise-function-async": "error", - "@typescript-eslint/require-array-sort-compare": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": "error", - "@typescript-eslint/restrict-template-expressions": "error", - "@typescript-eslint/return-await": "error", - "@typescript-eslint/sort-type-constituents": "error", - "@typescript-eslint/strict-boolean-expressions": "error", - "@typescript-eslint/switch-exhaustiveness-check": "error", - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/typedef": "error", - "@typescript-eslint/unbound-method": "error", - "@typescript-eslint/unified-signatures": "error", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", - "class-methods-use-this": "off", - "consistent-return": "off", - "default-param-last": "off", - "dot-notation": "off", - "init-declarations": "off", - "max-params": "off", - "no-array-constructor": "off", - "no-dupe-class-members": "off", - "no-empty-function": "off", - "no-implied-eval": "off", - "no-invalid-this": "off", - "no-loop-func": "off", - "no-loss-of-precision": "off", - "no-magic-numbers": "off", - "no-redeclare": "off", - "no-restricted-imports": "off", - "no-return-await": "off", - "no-shadow": "off", - "no-throw-literal": "off", - "no-unused-expressions": "off", - "no-unused-vars": "off", - "no-use-before-define": "off", - "no-useless-constructor": "off", - "prefer-destructuring": "off", - "prefer-promise-reject-errors": "off", - "require-await": "off", - }, - }, - "base": { - "parser": "@typescript-eslint/parser", - "parserOptions": { - "sourceType": "module", - }, - "plugins": [ - "@typescript-eslint", - ], - }, - "disable-type-checked": { - "parserOptions": { - "program": null, - "project": false, - }, - "rules": { - "@typescript-eslint/await-thenable": "off", - "@typescript-eslint/consistent-return": "off", - "@typescript-eslint/consistent-type-exports": "off", - "@typescript-eslint/dot-notation": "off", - "@typescript-eslint/naming-convention": "off", - "@typescript-eslint/no-array-delete": "off", - "@typescript-eslint/no-base-to-string": "off", - "@typescript-eslint/no-confusing-void-expression": "off", - "@typescript-eslint/no-duplicate-type-constituents": "off", - "@typescript-eslint/no-floating-promises": "off", - "@typescript-eslint/no-for-in-array": "off", - "@typescript-eslint/no-implied-eval": "off", - "@typescript-eslint/no-meaningless-void-operator": "off", - "@typescript-eslint/no-misused-promises": "off", - "@typescript-eslint/no-mixed-enums": "off", - "@typescript-eslint/no-redundant-type-constituents": "off", - "@typescript-eslint/no-throw-literal": "off", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off", - "@typescript-eslint/no-unnecessary-condition": "off", - "@typescript-eslint/no-unnecessary-qualifier": "off", - "@typescript-eslint/no-unnecessary-type-arguments": "off", - "@typescript-eslint/no-unnecessary-type-assertion": "off", - "@typescript-eslint/no-unsafe-argument": "off", - "@typescript-eslint/no-unsafe-assignment": "off", - "@typescript-eslint/no-unsafe-call": "off", - "@typescript-eslint/no-unsafe-enum-comparison": "off", - "@typescript-eslint/no-unsafe-member-access": "off", - "@typescript-eslint/no-unsafe-return": "off", - "@typescript-eslint/no-unsafe-unary-minus": "off", - "@typescript-eslint/no-useless-template-literals": "off", - "@typescript-eslint/non-nullable-type-assertion-style": "off", - "@typescript-eslint/only-throw-error": "off", - "@typescript-eslint/prefer-destructuring": "off", - "@typescript-eslint/prefer-find": "off", - "@typescript-eslint/prefer-includes": "off", - "@typescript-eslint/prefer-nullish-coalescing": "off", - "@typescript-eslint/prefer-optional-chain": "off", - "@typescript-eslint/prefer-promise-reject-errors": "off", - "@typescript-eslint/prefer-readonly": "off", - "@typescript-eslint/prefer-readonly-parameter-types": "off", - "@typescript-eslint/prefer-reduce-type-parameter": "off", - "@typescript-eslint/prefer-regexp-exec": "off", - "@typescript-eslint/prefer-return-this-type": "off", - "@typescript-eslint/prefer-string-starts-ends-with": "off", - "@typescript-eslint/promise-function-async": "off", - "@typescript-eslint/require-array-sort-compare": "off", - "@typescript-eslint/require-await": "off", - "@typescript-eslint/restrict-plus-operands": "off", - "@typescript-eslint/restrict-template-expressions": "off", - "@typescript-eslint/return-await": "off", - "@typescript-eslint/strict-boolean-expressions": "off", - "@typescript-eslint/switch-exhaustiveness-check": "off", - "@typescript-eslint/unbound-method": "off", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "off", - }, - }, - "eslint-recommended": { - "overrides": [ - { - "files": [ - "*.ts", - "*.tsx", - "*.mts", - "*.cts", - ], - "rules": { - "constructor-super": "off", - "getter-return": "off", - "no-const-assign": "off", - "no-dupe-args": "off", - "no-dupe-class-members": "off", - "no-dupe-keys": "off", - "no-func-assign": "off", - "no-import-assign": "off", - "no-new-symbol": "off", - "no-obj-calls": "off", - "no-redeclare": "off", - "no-setter-return": "off", - "no-this-before-super": "off", - "no-undef": "off", - "no-unreachable": "off", - "no-unsafe-negation": "off", - "no-var": "error", - "prefer-const": "error", - "prefer-rest-params": "error", - "prefer-spread": "error", - }, - }, - ], - }, - "recommended": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/ban-ts-comment": "error", - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/triple-slash-reference": "error", - "no-array-constructor": "off", - "no-loss-of-precision": "off", - "no-unused-vars": "off", - }, - }, - "recommended-requiring-type-checking": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": "error", - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": "error", - "@typescript-eslint/restrict-template-expressions": "error", - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unbound-method": "error", - "no-array-constructor": "off", - "no-implied-eval": "off", - "no-loss-of-precision": "off", - "no-unused-vars": "off", - "require-await": "off", - }, - }, - "recommended-type-checked": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": "error", - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": "error", - "@typescript-eslint/restrict-template-expressions": "error", - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unbound-method": "error", - "no-array-constructor": "off", - "no-implied-eval": "off", - "no-loss-of-precision": "off", - "no-unused-vars": "off", - "require-await": "off", - }, - }, - "recommended-type-checked-only": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": "error", - "@typescript-eslint/restrict-template-expressions": "error", - "@typescript-eslint/unbound-method": "error", - "no-implied-eval": "off", - "require-await": "off", - }, - }, - "strict": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/ban-ts-comment": [ - "error", - { - "minimumDescriptionLength": 10, - }, - ], - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-dynamic-delete": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-extraneous-class": "error", - "@typescript-eslint/no-invalid-void-type": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-non-null-assertion": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-useless-constructor": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/prefer-literal-enum-member": "error", - "@typescript-eslint/prefer-ts-expect-error": "error", - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unified-signatures": "error", - "no-array-constructor": "off", - "no-loss-of-precision": "off", - "no-unused-vars": "off", - "no-useless-constructor": "off", - }, - }, - "strict-type-checked": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": [ - "error", - { - "minimumDescriptionLength": 10, - }, - ], - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-array-delete": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-confusing-void-expression": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-dynamic-delete": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-extraneous-class": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-invalid-void-type": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-meaningless-void-operator": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-mixed-enums": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-non-null-assertion": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", - "@typescript-eslint/no-unnecessary-condition": "error", - "@typescript-eslint/no-unnecessary-type-arguments": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-useless-constructor": "error", - "@typescript-eslint/no-useless-template-literals": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/only-throw-error": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/prefer-includes": "error", - "@typescript-eslint/prefer-literal-enum-member": "error", - "@typescript-eslint/prefer-promise-reject-errors": "error", - "@typescript-eslint/prefer-reduce-type-parameter": "error", - "@typescript-eslint/prefer-return-this-type": "error", - "@typescript-eslint/prefer-ts-expect-error": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNullish": false, - "allowNumberAndString": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/restrict-template-expressions": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNever": false, - "allowNullish": false, - "allowNumber": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unbound-method": "error", - "@typescript-eslint/unified-signatures": "error", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", - "no-array-constructor": "off", - "no-implied-eval": "off", - "no-loss-of-precision": "off", - "no-throw-literal": "off", - "no-unused-vars": "off", - "no-useless-constructor": "off", - "prefer-promise-reject-errors": "off", - "require-await": "off", - }, - }, - "strict-type-checked-only": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/no-array-delete": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-confusing-void-expression": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-meaningless-void-operator": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-mixed-enums": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", - "@typescript-eslint/no-unnecessary-condition": "error", - "@typescript-eslint/no-unnecessary-type-arguments": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-useless-template-literals": "error", - "@typescript-eslint/only-throw-error": "error", - "@typescript-eslint/prefer-includes": "error", - "@typescript-eslint/prefer-promise-reject-errors": "error", - "@typescript-eslint/prefer-reduce-type-parameter": "error", - "@typescript-eslint/prefer-return-this-type": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNullish": false, - "allowNumberAndString": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/restrict-template-expressions": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNever": false, - "allowNullish": false, - "allowNumber": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/unbound-method": "error", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", - "no-implied-eval": "off", - "no-throw-literal": "off", - "prefer-promise-reject-errors": "off", - "require-await": "off", - }, - }, - "stylistic": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/adjacent-overload-signatures": "error", - "@typescript-eslint/array-type": "error", - "@typescript-eslint/ban-tslint-comment": "error", - "@typescript-eslint/class-literal-property-style": "error", - "@typescript-eslint/consistent-generic-constructors": "error", - "@typescript-eslint/consistent-indexed-object-style": "error", - "@typescript-eslint/consistent-type-assertions": "error", - "@typescript-eslint/consistent-type-definitions": "error", - "@typescript-eslint/no-confusing-non-null-assertion": "error", - "@typescript-eslint/no-empty-function": "error", - "@typescript-eslint/no-empty-interface": "error", - "@typescript-eslint/no-inferrable-types": "error", - "@typescript-eslint/prefer-for-of": "error", - "@typescript-eslint/prefer-function-type": "error", - "@typescript-eslint/prefer-namespace-keyword": "error", - "no-empty-function": "off", - }, - }, - "stylistic-type-checked": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/adjacent-overload-signatures": "error", - "@typescript-eslint/array-type": "error", - "@typescript-eslint/ban-tslint-comment": "error", - "@typescript-eslint/class-literal-property-style": "error", - "@typescript-eslint/consistent-generic-constructors": "error", - "@typescript-eslint/consistent-indexed-object-style": "error", - "@typescript-eslint/consistent-type-assertions": "error", - "@typescript-eslint/consistent-type-definitions": "error", - "@typescript-eslint/dot-notation": "error", - "@typescript-eslint/no-confusing-non-null-assertion": "error", - "@typescript-eslint/no-empty-function": "error", - "@typescript-eslint/no-empty-interface": "error", - "@typescript-eslint/no-inferrable-types": "error", - "@typescript-eslint/non-nullable-type-assertion-style": "error", - "@typescript-eslint/prefer-for-of": "error", - "@typescript-eslint/prefer-function-type": "error", - "@typescript-eslint/prefer-namespace-keyword": "error", - "@typescript-eslint/prefer-nullish-coalescing": "error", - "@typescript-eslint/prefer-optional-chain": "error", - "@typescript-eslint/prefer-string-starts-ends-with": "error", - "dot-notation": "off", - "no-empty-function": "off", - }, - }, - "stylistic-type-checked-only": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/dot-notation": "error", - "@typescript-eslint/non-nullable-type-assertion-style": "error", - "@typescript-eslint/prefer-nullish-coalescing": "error", - "@typescript-eslint/prefer-optional-chain": "error", - "@typescript-eslint/prefer-string-starts-ends-with": "error", - "dot-notation": "off", - }, - }, - }, - "meta": { - "name": "@typescript-eslint/eslint-plugin", - "version": "7.5.0", - }, - "rules": { - "adjacent-overload-signatures": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Require that function overload signatures be consecutive", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/adjacent-overload-signatures", - }, - "messages": { - "adjacentSignature": "All {{name}} signatures should be adjacent.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "array-type": { - "create": [Function], - "defaultOptions": [ - { - "default": "array", - }, - ], - "meta": { - "docs": { - "description": "Require consistently using either \`T[]\` or \`Array\` for arrays", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/array-type", - }, - "fixable": "code", - "messages": { - "errorStringArray": "Array type using '{{className}}<{{type}}>' is forbidden. Use '{{readonlyPrefix}}{{type}}[]' instead.", - "errorStringArraySimple": "Array type using '{{className}}<{{type}}>' is forbidden for simple types. Use '{{readonlyPrefix}}{{type}}[]' instead.", - "errorStringGeneric": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden. Use '{{className}}<{{type}}>' instead.", - "errorStringGenericSimple": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden for non-simple types. Use '{{className}}<{{type}}>' instead.", - }, - "schema": [ - { - "$defs": { - "arrayOption": { - "enum": [ - "array", - "generic", - "array-simple", - ], - "type": "string", - }, - }, - "additionalProperties": false, - "properties": { - "default": { - "$ref": "#/items/0/$defs/arrayOption", - "description": "The array type expected for mutable cases.", - }, - "readonly": { - "$ref": "#/items/0/$defs/arrayOption", - "description": "The array type expected for readonly cases. If omitted, the value for \`default\` will be used.", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "await-thenable": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow awaiting a value that is not a Thenable", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/await-thenable", - }, - "hasSuggestions": true, - "messages": { - "await": "Unexpected \`await\` of a non-Promise (non-"Thenable") value.", - "removeAwait": "Remove unnecessary \`await\`.", - }, - "schema": [], - "type": "problem", - }, - }, - "ban-ts-comment": { - "create": [Function], - "defaultOptions": [ - { - "minimumDescriptionLength": 3, - "ts-check": false, - "ts-expect-error": "allow-with-description", - "ts-ignore": true, - "ts-nocheck": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow \`@ts-\` comments or require descriptions after directives", - "recommended": { - "recommended": true, - "strict": [ - { - "minimumDescriptionLength": 10, - }, - ], - }, - "url": "https://typescript-eslint.io/rules/ban-ts-comment", - }, - "hasSuggestions": true, - "messages": { - "replaceTsIgnoreWithTsExpectError": "Replace "@ts-ignore" with "@ts-expect-error".", - "tsDirectiveComment": "Do not use "@ts-{{directive}}" because it alters compilation errors.", - "tsDirectiveCommentDescriptionNotMatchPattern": "The description for the "@ts-{{directive}}" directive must match the {{format}} format.", - "tsDirectiveCommentRequiresDescription": "Include a description after the "@ts-{{directive}}" directive to explain why the @ts-{{directive}} is necessary. The description must be {{minimumDescriptionLength}} characters or longer.", - "tsIgnoreInsteadOfExpectError": "Use "@ts-expect-error" instead of "@ts-ignore", as "@ts-ignore" will do nothing if the following line is error-free.", - }, - "schema": [ - { - "$defs": { - "directiveConfigSchema": { - "oneOf": [ - { - "default": true, - "type": "boolean", - }, - { - "enum": [ - "allow-with-description", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "descriptionFormat": { - "type": "string", - }, - }, - "type": "object", - }, - ], - }, - }, - "additionalProperties": false, - "properties": { - "minimumDescriptionLength": { - "default": 3, - "type": "number", - }, - "ts-check": { - "$ref": "#/items/0/$defs/directiveConfigSchema", - }, - "ts-expect-error": { - "$ref": "#/items/0/$defs/directiveConfigSchema", - }, - "ts-ignore": { - "$ref": "#/items/0/$defs/directiveConfigSchema", - }, - "ts-nocheck": { - "$ref": "#/items/0/$defs/directiveConfigSchema", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "ban-tslint-comment": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow \`// tslint:\` comments", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/ban-tslint-comment", - }, - "fixable": "code", - "messages": { - "commentDetected": "tslint comment detected: "{{ text }}"", - }, - "schema": [], - "type": "suggestion", - }, - }, - "ban-types": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "docs": { - "description": "Disallow certain types", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/ban-types", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "bannedTypeMessage": "Don't use \`{{name}}\` as a type.{{customMessage}}", - "bannedTypeReplacement": "Replace \`{{name}}\` with \`{{replacement}}\`.", - }, - "schema": [ - { - "$defs": { - "banConfig": { - "oneOf": [ - { - "description": "Bans the type with the default message", - "type": "null", - }, - { - "description": "Un-bans the type (useful when paired with \`extendDefaults\`)", - "enum": [ - false, - ], - "type": "boolean", - }, - { - "description": "Bans the type with the default message", - "enum": [ - true, - ], - "type": "boolean", - }, - { - "description": "Bans the type with a custom message", - "type": "string", - }, - { - "additionalProperties": false, - "description": "Bans a type", - "properties": { - "fixWith": { - "description": "Type to autofix replace with. Note that autofixers can be applied automatically - so you need to be careful with this option.", - "type": "string", - }, - "message": { - "description": "Custom error message", - "type": "string", - }, - "suggest": { - "additionalItems": false, - "description": "Types to suggest replacing with.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - }, - }, - "additionalProperties": false, - "properties": { - "extendDefaults": { - "type": "boolean", - }, - "types": { - "additionalProperties": { - "$ref": "#/items/0/$defs/banConfig", - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "block-spacing": { - "create": [Function], - "defaultOptions": [ - "always", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow or enforce spaces inside of blocks after opening block and before closing block", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/block-spacing", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "extra": "Unexpected space(s) {{location}} '{{token}}'.", - "missing": "Requires a space {{location}} '{{token}}'.", - }, - "replacedBy": [ - "@stylistic/ts/block-spacing", - ], - "schema": [ - { - "enum": [ - "always", - "never", - ], - }, - ], - "type": "layout", - }, - }, - "brace-style": { - "create": [Function], - "defaultOptions": [ - "1tbs", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent brace style for blocks", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/brace-style", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "blockSameLine": "Statement inside of curly braces should be on next line.", - "nextLineClose": "Closing curly brace does not appear on the same line as the subsequent block.", - "nextLineOpen": "Opening curly brace does not appear on the same line as controlling statement.", - "sameLineClose": "Closing curly brace appears on the same line as the subsequent block.", - "sameLineOpen": "Opening curly brace appears on the same line as controlling statement.", - "singleLineClose": "Closing curly brace should be on the same line as opening curly brace or on the line after the previous block.", - }, - "replacedBy": [ - "@stylistic/ts/brace-style", - ], - "schema": [ - { - "enum": [ - "1tbs", - "stroustrup", - "allman", - ], - }, - { - "additionalProperties": false, - "properties": { - "allowSingleLine": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "class-literal-property-style": { - "create": [Function], - "defaultOptions": [ - "fields", - ], - "meta": { - "docs": { - "description": "Enforce that literals on classes are exposed in a consistent style", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/class-literal-property-style", - }, - "hasSuggestions": true, - "messages": { - "preferFieldStyle": "Literals should be exposed using readonly fields.", - "preferFieldStyleSuggestion": "Replace the literals with readonly fields.", - "preferGetterStyle": "Literals should be exposed using getters.", - "preferGetterStyleSuggestion": "Replace the literals with getters.", - }, - "schema": [ - { - "enum": [ - "fields", - "getters", - ], - "type": "string", - }, - ], - "type": "problem", - }, - }, - "class-methods-use-this": { - "create": [Function], - "defaultOptions": [ - { - "enforceForClassFields": true, - "exceptMethods": [], - "ignoreClassesThatImplementAnInterface": false, - "ignoreOverrideMethods": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce that class methods utilize \`this\`", - "extendsBaseRule": true, - "requiresTypeChecking": false, - "url": "https://typescript-eslint.io/rules/class-methods-use-this", - }, - "messages": { - "missingThis": "Expected 'this' to be used by class {{name}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "enforceForClassFields": { - "default": true, - "description": "Enforces that functions used as instance field initializers utilize \`this\`", - "type": "boolean", - }, - "exceptMethods": { - "description": "Allows specified method names to be ignored with this rule", - "items": { - "type": "string", - }, - "type": "array", - }, - "ignoreClassesThatImplementAnInterface": { - "description": "Ignore classes that specifically implement some interface", - "oneOf": [ - { - "description": "Ignore all classes that implement an interface", - "type": "boolean", - }, - { - "description": "Ignore only the public fields of classes that implement an interface", - "enum": [ - "public-fields", - ], - "type": "string", - }, - ], - }, - "ignoreOverrideMethods": { - "description": "Ignore members marked with the \`override\` modifier", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "comma-dangle": { - "create": [Function], - "defaultOptions": [ - "never", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow trailing commas", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/comma-dangle", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "missing": "Missing trailing comma.", - "unexpected": "Unexpected trailing comma.", - }, - "replacedBy": [ - "@stylistic/ts/comma-dangle", - ], - "schema": { - "$defs": { - "value": { - "enum": [ - "always-multiline", - "always", - "never", - "only-multiline", - ], - "type": "string", - }, - "valueWithIgnore": { - "enum": [ - "always-multiline", - "always", - "never", - "only-multiline", - "ignore", - ], - "type": "string", - }, - }, - "additionalItems": false, - "items": [ - { - "oneOf": [ - { - "$ref": "#/$defs/value", - }, - { - "additionalProperties": false, - "properties": { - "arrays": { - "$ref": "#/$defs/valueWithIgnore", - }, - "enums": { - "$ref": "#/$defs/valueWithIgnore", - }, - "exports": { - "$ref": "#/$defs/valueWithIgnore", - }, - "functions": { - "$ref": "#/$defs/valueWithIgnore", - }, - "generics": { - "$ref": "#/$defs/valueWithIgnore", - }, - "imports": { - "$ref": "#/$defs/valueWithIgnore", - }, - "objects": { - "$ref": "#/$defs/valueWithIgnore", - }, - "tuples": { - "$ref": "#/$defs/valueWithIgnore", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "array", - }, - "type": "layout", - }, - }, - "comma-spacing": { - "create": [Function], - "defaultOptions": [ - { - "after": true, - "before": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing before and after commas", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/comma-spacing", - }, - "fixable": "whitespace", - "messages": { - "missing": "A space is required {{loc}} ','.", - "unexpected": "There should be no space {{loc}} ','.", - }, - "replacedBy": [ - "@stylistic/ts/comma-spacing", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "after": { - "default": true, - "type": "boolean", - }, - "before": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "consistent-generic-constructors": { - "create": [Function], - "defaultOptions": [ - "constructor", - ], - "meta": { - "docs": { - "description": "Enforce specifying generic type arguments on type annotation or constructor name of a constructor call", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/consistent-generic-constructors", - }, - "fixable": "code", - "messages": { - "preferConstructor": "The generic type arguments should be specified as part of the constructor type arguments.", - "preferTypeAnnotation": "The generic type arguments should be specified as part of the type annotation.", - }, - "schema": [ - { - "enum": [ - "type-annotation", - "constructor", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "consistent-indexed-object-style": { - "create": [Function], - "defaultOptions": [ - "record", - ], - "meta": { - "docs": { - "description": "Require or disallow the \`Record\` type", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/consistent-indexed-object-style", - }, - "fixable": "code", - "messages": { - "preferIndexSignature": "An index signature is preferred over a record.", - "preferRecord": "A record is preferred over an index signature.", - }, - "schema": [ - { - "enum": [ - "record", - "index-signature", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "consistent-return": { - "create": [Function], - "defaultOptions": [ - { - "treatUndefinedAsUnspecified": false, - }, - ], - "meta": { - "docs": { - "description": "Require \`return\` statements to either always or never specify values", - "extendsBaseRule": true, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/consistent-return", - }, - "hasSuggestions": undefined, - "messages": { - "missingReturn": "Expected to return a value at the end of {{name}}.", - "missingReturnValue": "{{name}} expected a return value.", - "unexpectedReturnValue": "{{name}} expected no return value.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "treatUndefinedAsUnspecified": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "consistent-type-assertions": { - "create": [Function], - "defaultOptions": [ - { - "assertionStyle": "as", - "objectLiteralTypeAssertions": "allow", - }, - ], - "meta": { - "docs": { - "description": "Enforce consistent usage of type assertions", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/consistent-type-assertions", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "angle-bracket": "Use '<{{cast}}>' instead of 'as {{cast}}'.", - "as": "Use 'as {{cast}}' instead of '<{{cast}}>'.", - "never": "Do not use any type assertions.", - "replaceObjectTypeAssertionWithAnnotation": "Use const x: {{cast}} = { ... } instead.", - "replaceObjectTypeAssertionWithSatisfies": "Use const x = { ... } satisfies {{cast}} instead.", - "unexpectedObjectTypeAssertion": "Always prefer const x: T = { ... }.", - }, - "schema": [ - { - "oneOf": [ - { - "additionalProperties": false, - "properties": { - "assertionStyle": { - "enum": [ - "never", - ], - "type": "string", - }, - }, - "required": [ - "assertionStyle", - ], - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "assertionStyle": { - "enum": [ - "as", - "angle-bracket", - ], - "type": "string", - }, - "objectLiteralTypeAssertions": { - "enum": [ - "allow", - "allow-as-parameter", - "never", - ], - "type": "string", - }, - }, - "required": [ - "assertionStyle", - ], - "type": "object", - }, - ], - }, - ], - "type": "suggestion", - }, - }, - "consistent-type-definitions": { - "create": [Function], - "defaultOptions": [ - "interface", - ], - "meta": { - "docs": { - "description": "Enforce type definitions to consistently use either \`interface\` or \`type\`", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/consistent-type-definitions", - }, - "fixable": "code", - "messages": { - "interfaceOverType": "Use an \`interface\` instead of a \`type\`.", - "typeOverInterface": "Use a \`type\` instead of an \`interface\`.", - }, - "schema": [ - { - "enum": [ - "interface", - "type", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "consistent-type-exports": { - "create": [Function], - "defaultOptions": [ - { - "fixMixedExportsWithInlineTypeSpecifier": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce consistent usage of type exports", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/consistent-type-exports", - }, - "fixable": "code", - "messages": { - "multipleExportsAreTypes": "Type exports {{exportNames}} are not values and should be exported using \`export type\`.", - "singleExportIsType": "Type export {{exportNames}} is not a value and should be exported using \`export type\`.", - "typeOverValue": "All exports in the declaration are only used as types. Use \`export type\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "fixMixedExportsWithInlineTypeSpecifier": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "consistent-type-imports": { - "create": [Function], - "defaultOptions": [ - { - "disallowTypeAnnotations": true, - "fixStyle": "separate-type-imports", - "prefer": "type-imports", - }, - ], - "meta": { - "docs": { - "description": "Enforce consistent usage of type imports", - "url": "https://typescript-eslint.io/rules/consistent-type-imports", - }, - "fixable": "code", - "messages": { - "avoidImportType": "Use an \`import\` instead of an \`import type\`.", - "noImportTypeAnnotations": "\`import()\` type annotations are forbidden.", - "someImportsAreOnlyTypes": "Imports {{typeImports}} are only used as type.", - "typeOverValue": "All imports in the declaration are only used as types. Use \`import type\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "disallowTypeAnnotations": { - "type": "boolean", - }, - "fixStyle": { - "enum": [ - "separate-type-imports", - "inline-type-imports", - ], - "type": "string", - }, - "prefer": { - "enum": [ - "type-imports", - "no-type-imports", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "default-param-last": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce default parameters to be last", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/default-param-last", - }, - "messages": { - "shouldBeLast": "Default parameters should be last.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "dot-notation": { - "create": [Function], - "defaultOptions": [ - { - "allowIndexSignaturePropertyAccess": false, - "allowKeywords": true, - "allowPattern": "", - "allowPrivateClassPropertyAccess": false, - "allowProtectedClassPropertyAccess": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce dot notation whenever possible", - "extendsBaseRule": true, - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/dot-notation", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "useBrackets": ".{{key}} is a syntax error.", - "useDot": "[{{key}}] is better written in dot notation.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowIndexSignaturePropertyAccess": { - "default": false, - "type": "boolean", - }, - "allowKeywords": { - "default": true, - "type": "boolean", - }, - "allowPattern": { - "default": "", - "type": "string", - }, - "allowPrivateClassPropertyAccess": { - "default": false, - "type": "boolean", - }, - "allowProtectedClassPropertyAccess": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "explicit-function-return-type": { - "create": [Function], - "defaultOptions": [ - { - "allowConciseArrowFunctionExpressionsStartingWithVoid": false, - "allowDirectConstAssertionInArrowFunctions": true, - "allowExpressions": false, - "allowFunctionsWithoutTypeParameters": false, - "allowHigherOrderFunctions": true, - "allowIIFEs": false, - "allowTypedFunctionExpressions": true, - "allowedNames": [], - }, - ], - "meta": { - "docs": { - "description": "Require explicit return types on functions and class methods", - "url": "https://typescript-eslint.io/rules/explicit-function-return-type", - }, - "messages": { - "missingReturnType": "Missing return type on function.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowConciseArrowFunctionExpressionsStartingWithVoid": { - "description": "Whether to allow arrow functions that start with the \`void\` keyword.", - "type": "boolean", - }, - "allowDirectConstAssertionInArrowFunctions": { - "description": "Whether to ignore arrow functions immediately returning a \`as const\` value.", - "type": "boolean", - }, - "allowExpressions": { - "description": "Whether to ignore function expressions (functions which are not part of a declaration).", - "type": "boolean", - }, - "allowFunctionsWithoutTypeParameters": { - "description": "Whether to ignore functions that don't have generic type parameters.", - "type": "boolean", - }, - "allowHigherOrderFunctions": { - "description": "Whether to ignore functions immediately returning another function expression.", - "type": "boolean", - }, - "allowIIFEs": { - "description": "Whether to ignore immediately invoked function expressions (IIFEs).", - "type": "boolean", - }, - "allowTypedFunctionExpressions": { - "description": "Whether to ignore type annotations on the variable of function expressions.", - "type": "boolean", - }, - "allowedNames": { - "description": "An array of function/method names that will not have their arguments or return values checked.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "explicit-member-accessibility": { - "create": [Function], - "defaultOptions": [ - { - "accessibility": "explicit", - }, - ], - "meta": { - "docs": { - "description": "Require explicit accessibility modifiers on class properties and methods", - "url": "https://typescript-eslint.io/rules/explicit-member-accessibility", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "addExplicitAccessibility": "Add '{{ type }}' accessibility modifier", - "missingAccessibility": "Missing accessibility modifier on {{type}} {{name}}.", - "unwantedPublicAccessibility": "Public accessibility modifier on {{type}} {{name}}.", - }, - "schema": [ - { - "$defs": { - "accessibilityLevel": { - "oneOf": [ - { - "description": "Always require an accessor.", - "enum": [ - "explicit", - ], - "type": "string", - }, - { - "description": "Require an accessor except when public.", - "enum": [ - "no-public", - ], - "type": "string", - }, - { - "description": "Never check whether there is an accessor.", - "enum": [ - "off", - ], - "type": "string", - }, - ], - }, - }, - "additionalProperties": false, - "properties": { - "accessibility": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "ignoredMethodNames": { - "items": { - "type": "string", - }, - "type": "array", - }, - "overrides": { - "additionalProperties": false, - "properties": { - "accessors": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "constructors": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "methods": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "parameterProperties": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "properties": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "explicit-module-boundary-types": { - "create": [Function], - "defaultOptions": [ - { - "allowArgumentsExplicitlyTypedAsAny": false, - "allowDirectConstAssertionInArrowFunctions": true, - "allowHigherOrderFunctions": true, - "allowTypedFunctionExpressions": true, - "allowedNames": [], - }, - ], - "meta": { - "docs": { - "description": "Require explicit return and argument types on exported functions' and classes' public class methods", - "url": "https://typescript-eslint.io/rules/explicit-module-boundary-types", - }, - "messages": { - "anyTypedArg": "Argument '{{name}}' should be typed with a non-any type.", - "anyTypedArgUnnamed": "{{type}} argument should be typed with a non-any type.", - "missingArgType": "Argument '{{name}}' should be typed.", - "missingArgTypeUnnamed": "{{type}} argument should be typed.", - "missingReturnType": "Missing return type on function.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowArgumentsExplicitlyTypedAsAny": { - "description": "Whether to ignore arguments that are explicitly typed as \`any\`.", - "type": "boolean", - }, - "allowDirectConstAssertionInArrowFunctions": { - "description": "Whether to ignore return type annotations on body-less arrow functions that return an \`as const\` type assertion. -You must still type the parameters of the function.", - "type": "boolean", - }, - "allowHigherOrderFunctions": { - "description": "Whether to ignore return type annotations on functions immediately returning another function expression. -You must still type the parameters of the function.", - "type": "boolean", - }, - "allowTypedFunctionExpressions": { - "description": "Whether to ignore type annotations on the variable of a function expression.", - "type": "boolean", - }, - "allowedNames": { - "description": "An array of function/method names that will not have their arguments or return values checked.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "func-call-spacing": { - "create": [Function], - "defaultOptions": [ - "never", - {}, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow spacing between function identifiers and their invocations", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/func-call-spacing", - }, - "fixable": "whitespace", - "messages": { - "missing": "Missing space between function name and paren.", - "unexpectedNewline": "Unexpected newline between function name and paren.", - "unexpectedWhitespace": "Unexpected whitespace between function name and paren.", - }, - "replacedBy": [ - "@stylistic/ts/func-call-spacing", - ], - "schema": { - "anyOf": [ - { - "items": [ - { - "enum": [ - "never", - ], - "type": "string", - }, - ], - "maxItems": 1, - "minItems": 0, - "type": "array", - }, - { - "items": [ - { - "enum": [ - "always", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "allowNewlines": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - ], - }, - "type": "layout", - }, - }, - "indent": { - "create": [Function], - "defaultOptions": [ - 4, - { - "SwitchCase": 1, - "flatTernaryExpressions": false, - "ignoredNodes": [], - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent indentation", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/indent", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "wrongIndentation": "Expected indentation of {{expected}} but found {{actual}}.", - }, - "replacedBy": [ - "@stylistic/ts/indent", - ], - "schema": [ - { - "oneOf": [ - { - "enum": [ - "tab", - ], - }, - { - "minimum": 0, - "type": "integer", - }, - ], - }, - { - "additionalProperties": false, - "properties": { - "ArrayExpression": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "CallExpression": { - "additionalProperties": false, - "properties": { - "arguments": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - "FunctionDeclaration": { - "additionalProperties": false, - "properties": { - "body": { - "minimum": 0, - "type": "integer", - }, - "parameters": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - "FunctionExpression": { - "additionalProperties": false, - "properties": { - "body": { - "minimum": 0, - "type": "integer", - }, - "parameters": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - "ImportDeclaration": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "MemberExpression": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "off", - ], - }, - ], - }, - "ObjectExpression": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "StaticBlock": { - "additionalProperties": false, - "properties": { - "body": { - "minimum": 0, - "type": "integer", - }, - }, - "type": "object", - }, - "SwitchCase": { - "default": 0, - "minimum": 0, - "type": "integer", - }, - "VariableDeclarator": { - "oneOf": [ - { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - { - "additionalProperties": false, - "properties": { - "const": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "let": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "var": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - ], - }, - "flatTernaryExpressions": { - "default": false, - "type": "boolean", - }, - "ignoreComments": { - "default": false, - "type": "boolean", - }, - "ignoredNodes": { - "items": { - "not": { - "pattern": ":exit$", - }, - "type": "string", - }, - "type": "array", - }, - "offsetTernaryExpressions": { - "default": false, - "type": "boolean", - }, - "outerIIFEBody": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "init-declarations": { - "create": [Function], - "defaultOptions": [ - "always", - ], - "meta": { - "docs": { - "description": "Require or disallow initialization in variable declarations", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/init-declarations", - }, - "hasSuggestions": undefined, - "messages": { - "initialized": "Variable '{{idName}}' should be initialized on declaration.", - "notInitialized": "Variable '{{idName}}' should not be initialized on declaration.", - }, - "schema": { - "anyOf": [ - { - "items": [ - { - "enum": [ - "always", - ], - }, - ], - "maxItems": 1, - "minItems": 0, - "type": "array", - }, - { - "items": [ - { - "enum": [ - "never", - ], - }, - { - "additionalProperties": false, - "properties": { - "ignoreForLoopInit": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - ], - }, - "type": "suggestion", - }, - }, - "key-spacing": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing between property names and type annotations in types and interfaces", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/key-spacing", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "extraKey": "Extra space after {{computed}}key '{{key}}'.", - "extraValue": "Extra space before value for {{computed}}key '{{key}}'.", - "missingKey": "Missing space after {{computed}}key '{{key}}'.", - "missingValue": "Missing space before value for {{computed}}key '{{key}}'.", - }, - "replacedBy": [ - "@stylistic/ts/key-spacing", - ], - "schema": [ - { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "align": { - "anyOf": [ - { - "enum": [ - "colon", - "value", - ], - }, - { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - "on": { - "enum": [ - "colon", - "value", - ], - }, - }, - "type": "object", - }, - ], - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "multiLine": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "align": { - "anyOf": [ - { - "enum": [ - "colon", - "value", - ], - }, - { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - "on": { - "enum": [ - "colon", - "value", - ], - }, - }, - "type": "object", - }, - ], - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - "singleLine": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "align": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - "on": { - "enum": [ - "colon", - "value", - ], - }, - }, - "type": "object", - }, - "multiLine": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - "singleLine": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "layout", - }, - }, - "keyword-spacing": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing before and after keywords", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/keyword-spacing", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "expectedAfter": "Expected space(s) after "{{value}}".", - "expectedBefore": "Expected space(s) before "{{value}}".", - "unexpectedAfter": "Unexpected space(s) after "{{value}}".", - "unexpectedBefore": "Unexpected space(s) before "{{value}}".", - }, - "replacedBy": [ - "@stylistic/ts/keyword-spacing", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "after": { - "default": true, - "type": "boolean", - }, - "before": { - "default": true, - "type": "boolean", - }, - "overrides": { - "additionalProperties": false, - "properties": { - "abstract": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "as": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "async": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "await": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "boolean": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "break": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "byte": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "case": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "catch": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "char": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "class": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "const": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "continue": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "debugger": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "default": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "delete": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "do": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "double": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "else": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "enum": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "export": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "extends": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "false": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "final": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "finally": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "float": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "for": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "from": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "function": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "get": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "goto": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "if": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "implements": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "import": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "in": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "instanceof": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "int": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "interface": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "let": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "long": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "native": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "new": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "null": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "of": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "package": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "private": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "protected": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "public": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "return": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "set": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "short": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "static": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "super": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "switch": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "synchronized": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "this": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "throw": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "throws": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "transient": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "true": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "try": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "type": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "typeof": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "var": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "void": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "volatile": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "while": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "with": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "yield": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "lines-around-comment": { - "create": [Function], - "defaultOptions": [ - { - "beforeBlockComment": true, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require empty lines around comments", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/lines-around-comment", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "after": "Expected line after comment.", - "before": "Expected line before comment.", - }, - "replacedBy": [ - "@stylistic/ts/lines-around-comment", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "afterBlockComment": { - "default": false, - "type": "boolean", - }, - "afterLineComment": { - "default": false, - "type": "boolean", - }, - "allowArrayEnd": { - "type": "boolean", - }, - "allowArrayStart": { - "type": "boolean", - }, - "allowBlockEnd": { - "default": false, - "type": "boolean", - }, - "allowBlockStart": { - "default": false, - "type": "boolean", - }, - "allowClassEnd": { - "type": "boolean", - }, - "allowClassStart": { - "type": "boolean", - }, - "allowEnumEnd": { - "type": "boolean", - }, - "allowEnumStart": { - "type": "boolean", - }, - "allowInterfaceEnd": { - "type": "boolean", - }, - "allowInterfaceStart": { - "type": "boolean", - }, - "allowModuleEnd": { - "type": "boolean", - }, - "allowModuleStart": { - "type": "boolean", - }, - "allowObjectEnd": { - "type": "boolean", - }, - "allowObjectStart": { - "type": "boolean", - }, - "allowTypeEnd": { - "type": "boolean", - }, - "allowTypeStart": { - "type": "boolean", - }, - "applyDefaultIgnorePatterns": { - "type": "boolean", - }, - "beforeBlockComment": { - "default": true, - "type": "boolean", - }, - "beforeLineComment": { - "default": false, - "type": "boolean", - }, - "ignorePattern": { - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "lines-between-class-members": { - "create": [Function], - "defaultOptions": [ - "always", - { - "exceptAfterOverload": true, - "exceptAfterSingleLine": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow an empty line between class members", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/lines-between-class-members", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "always": "Expected blank line between class members.", - "never": "Unexpected blank line between class members.", - }, - "replacedBy": [ - "@stylistic/ts/lines-between-class-members", - ], - "schema": [ - { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "enforce": { - "items": { - "additionalProperties": false, - "properties": { - "blankLine": { - "enum": [ - "always", - "never", - ], - }, - "next": { - "enum": [ - "method", - "field", - "*", - ], - }, - "prev": { - "enum": [ - "method", - "field", - "*", - ], - }, - }, - "required": [ - "blankLine", - "prev", - "next", - ], - "type": "object", - }, - "minItems": 1, - "type": "array", - }, - }, - "required": [ - "enforce", - ], - "type": "object", - }, - { - "enum": [ - "always", - "never", - ], - }, - ], - }, - { - "additionalProperties": false, - "properties": { - "exceptAfterOverload": { - "default": true, - "type": "boolean", - }, - "exceptAfterSingleLine": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "max-params": { - "create": [Function], - "defaultOptions": [ - { - "countVoidThis": false, - "max": 3, - }, - ], - "meta": { - "docs": { - "description": "Enforce a maximum number of parameters in function definitions", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/max-params", - }, - "messages": { - "exceed": "{{name}} has too many parameters ({{count}}). Maximum allowed is {{max}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "countVoidThis": { - "type": "boolean", - }, - "max": { - "minimum": 0, - "type": "integer", - }, - "maximum": { - "minimum": 0, - "type": "integer", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "member-delimiter-style": { - "create": [Function], - "defaultOptions": [ - { - "multiline": { - "delimiter": "semi", - "requireLast": true, - }, - "multilineDetection": "brackets", - "singleline": { - "delimiter": "semi", - "requireLast": false, - }, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require a specific member delimiter style for interfaces and type literals", - "url": "https://typescript-eslint.io/rules/member-delimiter-style", - }, - "fixable": "whitespace", - "messages": { - "expectedComma": "Expected a comma.", - "expectedSemi": "Expected a semicolon.", - "unexpectedComma": "Unexpected separator (,).", - "unexpectedSemi": "Unexpected separator (;).", - }, - "replacedBy": [ - "@stylistic/ts/member-delimiter-style", - ], - "schema": [ - { - "$defs": { - "delimiterConfig": { - "additionalProperties": false, - "properties": { - "multiline": { - "additionalProperties": false, - "properties": { - "delimiter": { - "$ref": "#/items/0/$defs/multiLineOption", - }, - "requireLast": { - "type": "boolean", - }, - }, - "type": "object", - }, - "singleline": { - "additionalProperties": false, - "properties": { - "delimiter": { - "$ref": "#/items/0/$defs/singleLineOption", - }, - "requireLast": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - "multiLineOption": { - "enum": [ - "none", - "semi", - "comma", - ], - "type": "string", - }, - "singleLineOption": { - "enum": [ - "semi", - "comma", - ], - "type": "string", - }, - }, - "additionalProperties": false, - "properties": { - "multiline": { - "additionalProperties": false, - "properties": { - "delimiter": { - "$ref": "#/items/0/$defs/multiLineOption", - }, - "requireLast": { - "type": "boolean", - }, - }, - "type": "object", - }, - "multilineDetection": { - "enum": [ - "brackets", - "last-member", - ], - "type": "string", - }, - "overrides": { - "additionalProperties": false, - "properties": { - "interface": { - "$ref": "#/items/0/$defs/delimiterConfig", - }, - "typeLiteral": { - "$ref": "#/items/0/$defs/delimiterConfig", - }, - }, - "type": "object", - }, - "singleline": { - "additionalProperties": false, - "properties": { - "delimiter": { - "$ref": "#/items/0/$defs/singleLineOption", - }, - "requireLast": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "member-ordering": { - "create": [Function], - "defaultOptions": [ - { - "default": { - "memberTypes": [ - "signature", - "call-signature", - "public-static-field", - "protected-static-field", - "private-static-field", - "#private-static-field", - "public-decorated-field", - "protected-decorated-field", - "private-decorated-field", - "public-instance-field", - "protected-instance-field", - "private-instance-field", - "#private-instance-field", - "public-abstract-field", - "protected-abstract-field", - "public-field", - "protected-field", - "private-field", - "#private-field", - "static-field", - "instance-field", - "abstract-field", - "decorated-field", - "field", - "static-initialization", - "public-constructor", - "protected-constructor", - "private-constructor", - "constructor", - "public-static-accessor", - "protected-static-accessor", - "private-static-accessor", - "#private-static-accessor", - "public-decorated-accessor", - "protected-decorated-accessor", - "private-decorated-accessor", - "public-instance-accessor", - "protected-instance-accessor", - "private-instance-accessor", - "#private-instance-accessor", - "public-abstract-accessor", - "protected-abstract-accessor", - "public-accessor", - "protected-accessor", - "private-accessor", - "#private-accessor", - "static-accessor", - "instance-accessor", - "abstract-accessor", - "decorated-accessor", - "accessor", - "public-static-get", - "protected-static-get", - "private-static-get", - "#private-static-get", - "public-decorated-get", - "protected-decorated-get", - "private-decorated-get", - "public-instance-get", - "protected-instance-get", - "private-instance-get", - "#private-instance-get", - "public-abstract-get", - "protected-abstract-get", - "public-get", - "protected-get", - "private-get", - "#private-get", - "static-get", - "instance-get", - "abstract-get", - "decorated-get", - "get", - "public-static-set", - "protected-static-set", - "private-static-set", - "#private-static-set", - "public-decorated-set", - "protected-decorated-set", - "private-decorated-set", - "public-instance-set", - "protected-instance-set", - "private-instance-set", - "#private-instance-set", - "public-abstract-set", - "protected-abstract-set", - "public-set", - "protected-set", - "private-set", - "#private-set", - "static-set", - "instance-set", - "abstract-set", - "decorated-set", - "set", - "public-static-method", - "protected-static-method", - "private-static-method", - "#private-static-method", - "public-decorated-method", - "protected-decorated-method", - "private-decorated-method", - "public-instance-method", - "protected-instance-method", - "private-instance-method", - "#private-instance-method", - "public-abstract-method", - "protected-abstract-method", - "public-method", - "protected-method", - "private-method", - "#private-method", - "static-method", - "instance-method", - "abstract-method", - "decorated-method", - "method", - ], - }, - }, - ], - "meta": { - "docs": { - "description": "Require a consistent member declaration order", - "url": "https://typescript-eslint.io/rules/member-ordering", - }, - "messages": { - "incorrectGroupOrder": "Member {{name}} should be declared before all {{rank}} definitions.", - "incorrectOrder": "Member {{member}} should be declared before member {{beforeMember}}.", - "incorrectRequiredMembersOrder": "Member {{member}} should be declared after all {{optionalOrRequired}} members.", - }, - "schema": [ - { - "$defs": { - "allItems": { - "enum": [ - "readonly-signature", - "signature", - "readonly-field", - "public-readonly-field", - "public-decorated-readonly-field", - "decorated-readonly-field", - "static-readonly-field", - "public-static-readonly-field", - "instance-readonly-field", - "public-instance-readonly-field", - "abstract-readonly-field", - "public-abstract-readonly-field", - "protected-readonly-field", - "protected-decorated-readonly-field", - "protected-static-readonly-field", - "protected-instance-readonly-field", - "protected-abstract-readonly-field", - "private-readonly-field", - "private-decorated-readonly-field", - "private-static-readonly-field", - "private-instance-readonly-field", - "#private-readonly-field", - "#private-static-readonly-field", - "#private-instance-readonly-field", - "field", - "public-field", - "public-decorated-field", - "decorated-field", - "static-field", - "public-static-field", - "instance-field", - "public-instance-field", - "abstract-field", - "public-abstract-field", - "protected-field", - "protected-decorated-field", - "protected-static-field", - "protected-instance-field", - "protected-abstract-field", - "private-field", - "private-decorated-field", - "private-static-field", - "private-instance-field", - "#private-field", - "#private-static-field", - "#private-instance-field", - "method", - "public-method", - "public-decorated-method", - "decorated-method", - "static-method", - "public-static-method", - "instance-method", - "public-instance-method", - "abstract-method", - "public-abstract-method", - "protected-method", - "protected-decorated-method", - "protected-static-method", - "protected-instance-method", - "protected-abstract-method", - "private-method", - "private-decorated-method", - "private-static-method", - "private-instance-method", - "#private-method", - "#private-static-method", - "#private-instance-method", - "call-signature", - "constructor", - "public-constructor", - "protected-constructor", - "private-constructor", - "accessor", - "public-accessor", - "public-decorated-accessor", - "decorated-accessor", - "static-accessor", - "public-static-accessor", - "instance-accessor", - "public-instance-accessor", - "abstract-accessor", - "public-abstract-accessor", - "protected-accessor", - "protected-decorated-accessor", - "protected-static-accessor", - "protected-instance-accessor", - "protected-abstract-accessor", - "private-accessor", - "private-decorated-accessor", - "private-static-accessor", - "private-instance-accessor", - "#private-accessor", - "#private-static-accessor", - "#private-instance-accessor", - "get", - "public-get", - "public-decorated-get", - "decorated-get", - "static-get", - "public-static-get", - "instance-get", - "public-instance-get", - "abstract-get", - "public-abstract-get", - "protected-get", - "protected-decorated-get", - "protected-static-get", - "protected-instance-get", - "protected-abstract-get", - "private-get", - "private-decorated-get", - "private-static-get", - "private-instance-get", - "#private-get", - "#private-static-get", - "#private-instance-get", - "set", - "public-set", - "public-decorated-set", - "decorated-set", - "static-set", - "public-static-set", - "instance-set", - "public-instance-set", - "abstract-set", - "public-abstract-set", - "protected-set", - "protected-decorated-set", - "protected-static-set", - "protected-instance-set", - "protected-abstract-set", - "private-set", - "private-decorated-set", - "private-static-set", - "private-instance-set", - "#private-set", - "#private-static-set", - "#private-instance-set", - "static-initialization", - "static-static-initialization", - "public-static-static-initialization", - "instance-static-initialization", - "public-instance-static-initialization", - "abstract-static-initialization", - "public-abstract-static-initialization", - "protected-static-static-initialization", - "protected-instance-static-initialization", - "protected-abstract-static-initialization", - "private-static-static-initialization", - "private-instance-static-initialization", - "#private-static-static-initialization", - "#private-instance-static-initialization", - ], - "type": "string", - }, - "baseConfig": { - "oneOf": [ - { - "enum": [ - "never", - ], - "type": "string", - }, - { - "items": { - "oneOf": [ - { - "$ref": "#/items/0/$defs/allItems", - }, - { - "items": { - "$ref": "#/items/0/$defs/allItems", - }, - "type": "array", - }, - ], - }, - "type": "array", - }, - { - "additionalProperties": false, - "properties": { - "memberTypes": { - "oneOf": [ - { - "items": { - "oneOf": [ - { - "$ref": "#/items/0/$defs/allItems", - }, - { - "items": { - "$ref": "#/items/0/$defs/allItems", - }, - "type": "array", - }, - ], - }, - "type": "array", - }, - { - "enum": [ - "never", - ], - "type": "string", - }, - ], - }, - "optionalityOrder": { - "$ref": "#/items/0/$defs/optionalityOrderOptions", - }, - "order": { - "$ref": "#/items/0/$defs/orderOptions", - }, - }, - "type": "object", - }, - ], - }, - "optionalityOrderOptions": { - "enum": [ - "optional-first", - "required-first", - ], - "type": "string", - }, - "orderOptions": { - "enum": [ - "alphabetically", - "alphabetically-case-insensitive", - "as-written", - "natural", - "natural-case-insensitive", - ], - "type": "string", - }, - "typeItems": { - "enum": [ - "readonly-signature", - "signature", - "readonly-field", - "field", - "method", - "constructor", - ], - "type": "string", - }, - "typesConfig": { - "oneOf": [ - { - "enum": [ - "never", - ], - "type": "string", - }, - { - "items": { - "oneOf": [ - { - "$ref": "#/items/0/$defs/typeItems", - }, - { - "items": { - "$ref": "#/items/0/$defs/typeItems", - }, - "type": "array", - }, - ], - }, - "type": "array", - }, - { - "additionalProperties": false, - "properties": { - "memberTypes": { - "oneOf": [ - { - "items": { - "oneOf": [ - { - "$ref": "#/items/0/$defs/typeItems", - }, - { - "items": { - "$ref": "#/items/0/$defs/typeItems", - }, - "type": "array", - }, - ], - }, - "type": "array", - }, - { - "enum": [ - "never", - ], - "type": "string", - }, - ], - }, - "optionalityOrder": { - "$ref": "#/items/0/$defs/optionalityOrderOptions", - }, - "order": { - "$ref": "#/items/0/$defs/orderOptions", - }, - }, - "type": "object", - }, - ], - }, - }, - "additionalProperties": false, - "properties": { - "classExpressions": { - "$ref": "#/items/0/$defs/baseConfig", - }, - "classes": { - "$ref": "#/items/0/$defs/baseConfig", - }, - "default": { - "$ref": "#/items/0/$defs/baseConfig", - }, - "interfaces": { - "$ref": "#/items/0/$defs/typesConfig", - }, - "typeLiterals": { - "$ref": "#/items/0/$defs/typesConfig", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "method-signature-style": { - "create": [Function], - "defaultOptions": [ - "property", - ], - "meta": { - "docs": { - "description": "Enforce using a particular method signature syntax", - "url": "https://typescript-eslint.io/rules/method-signature-style", - }, - "fixable": "code", - "messages": { - "errorMethod": "Shorthand method signature is forbidden. Use a function property instead.", - "errorProperty": "Function property signature is forbidden. Use a method shorthand instead.", - }, - "schema": [ - { - "enum": [ - "property", - "method", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "naming-convention": { - "create": [Function], - "defaultOptions": [ - { - "format": [ - "camelCase", - ], - "leadingUnderscore": "allow", - "selector": "default", - "trailingUnderscore": "allow", - }, - { - "format": [ - "camelCase", - "PascalCase", - ], - "selector": "import", - }, - { - "format": [ - "camelCase", - "UPPER_CASE", - ], - "leadingUnderscore": "allow", - "selector": "variable", - "trailingUnderscore": "allow", - }, - { - "format": [ - "PascalCase", - ], - "selector": "typeLike", - }, - ], - "meta": { - "docs": { - "description": "Enforce naming conventions for everything across a codebase", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/naming-convention", - }, - "messages": { - "doesNotMatchFormat": "{{type}} name \`{{name}}\` must match one of the following formats: {{formats}}", - "doesNotMatchFormatTrimmed": "{{type}} name \`{{name}}\` trimmed as \`{{processedName}}\` must match one of the following formats: {{formats}}", - "missingAffix": "{{type}} name \`{{name}}\` must have one of the following {{position}}es: {{affixes}}", - "missingUnderscore": "{{type}} name \`{{name}}\` must have {{count}} {{position}} underscore(s).", - "satisfyCustom": "{{type}} name \`{{name}}\` must {{regexMatch}} the RegExp: {{regex}}", - "unexpectedUnderscore": "{{type}} name \`{{name}}\` must not have a {{position}} underscore.", - }, - "schema": { - "$defs": { - "formatOptionsConfig": { - "oneOf": [ - { - "additionalItems": false, - "items": { - "$ref": "#/$defs/predefinedFormats", - }, - "type": "array", - }, - { - "type": "null", - }, - ], - }, - "matchRegexConfig": { - "additionalProperties": false, - "properties": { - "match": { - "type": "boolean", - }, - "regex": { - "type": "string", - }, - }, - "required": [ - "match", - "regex", - ], - "type": "object", - }, - "predefinedFormats": { - "enum": [ - "camelCase", - "strictCamelCase", - "PascalCase", - "StrictPascalCase", - "snake_case", - "UPPER_CASE", - ], - "type": "string", - }, - "prefixSuffixConfig": { - "additionalItems": false, - "items": { - "minLength": 1, - "type": "string", - }, - "type": "array", - }, - "typeModifiers": { - "enum": [ - "boolean", - "string", - "number", - "function", - "array", - ], - "type": "string", - }, - "underscoreOptions": { - "enum": [ - "forbid", - "allow", - "require", - "requireDouble", - "allowDouble", - "allowSingleOrDouble", - ], - "type": "string", - }, - }, - "additionalItems": false, - "items": { - "oneOf": [ - { - "additionalProperties": false, - "description": "Multiple selectors in one config", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "const", - "readonly", - "static", - "public", - "protected", - "private", - "#private", - "abstract", - "destructured", - "global", - "exported", - "unused", - "requiresQuotes", - "override", - "async", - "default", - "namespace", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "additionalItems": false, - "items": { - "enum": [ - "default", - "variableLike", - "memberLike", - "typeLike", - "method", - "property", - "accessor", - "variable", - "function", - "parameter", - "parameterProperty", - "classicAccessor", - "enumMember", - "classMethod", - "objectLiteralMethod", - "typeMethod", - "classProperty", - "objectLiteralProperty", - "typeProperty", - "autoAccessor", - "class", - "interface", - "typeAlias", - "enum", - "typeParameter", - "import", - ], - "type": "string", - }, - "type": "array", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'default'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "const", - "readonly", - "static", - "public", - "protected", - "private", - "#private", - "abstract", - "destructured", - "global", - "exported", - "unused", - "requiresQuotes", - "override", - "async", - "default", - "namespace", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "default", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'variableLike'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "unused", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "variableLike", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'variable'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "const", - "destructured", - "exported", - "global", - "unused", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "variable", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'function'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "exported", - "global", - "unused", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "function", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'parameter'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "destructured", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "parameter", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'memberLike'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "readonly", - "requiresQuotes", - "static", - "override", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "memberLike", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'classProperty'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "readonly", - "requiresQuotes", - "static", - "override", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "classProperty", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'objectLiteralProperty'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "public", - "requiresQuotes", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "objectLiteralProperty", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeProperty'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "public", - "readonly", - "requiresQuotes", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeProperty", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'parameterProperty'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "private", - "protected", - "public", - "readonly", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "parameterProperty", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'property'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "readonly", - "requiresQuotes", - "static", - "override", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "property", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'classMethod'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "classMethod", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'objectLiteralMethod'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "public", - "requiresQuotes", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "objectLiteralMethod", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeMethod'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "public", - "requiresQuotes", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeMethod", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'method'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "method", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'classicAccessor'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "classicAccessor", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'autoAccessor'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "autoAccessor", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'accessor'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "accessor", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'enumMember'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "requiresQuotes", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "enumMember", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeLike'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeLike", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'class'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "class", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'interface'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "interface", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeAlias'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeAlias", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'enum'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "enum", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeParameter'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeParameter", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'import'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "default", - "namespace", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "import", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - ], - }, - "type": "array", - }, - "type": "suggestion", - }, - }, - "no-array-constructor": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow generic \`Array\` constructors", - "extendsBaseRule": true, - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-array-constructor", - }, - "fixable": "code", - "messages": { - "useLiteral": "The array literal notation [] is preferable.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-array-delete": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow using the \`delete\` operator on array values", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-array-delete", - }, - "hasSuggestions": true, - "messages": { - "noArrayDelete": "Using the \`delete\` operator with an array expression is unsafe.", - "useSplice": "Use \`array.splice()\` instead.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-base-to-string": { - "create": [Function], - "defaultOptions": [ - { - "ignoredTypeNames": [ - "Error", - "RegExp", - "URL", - "URLSearchParams", - ], - }, - ], - "meta": { - "docs": { - "description": "Require \`.toString()\` to only be called on objects which provide useful information when stringified", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-base-to-string", - }, - "messages": { - "baseToString": "'{{name}}' {{certainty}} evaluate to '[object Object]' when stringified.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoredTypeNames": { - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-confusing-non-null-assertion": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow non-null assertion in locations that may be confusing", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/no-confusing-non-null-assertion", - }, - "hasSuggestions": true, - "messages": { - "confusingAssign": "Confusing combinations of non-null assertion and equal test like "a! = b", which looks very similar to not equal "a != b".", - "confusingEqual": "Confusing combinations of non-null assertion and equal test like "a! == b", which looks very similar to not equal "a !== b".", - "notNeedInAssign": "Unnecessary non-null assertion (!) in assignment left hand.", - "notNeedInEqualTest": "Unnecessary non-null assertion (!) in equal test.", - "wrapUpLeft": "Wrap up left hand to avoid putting non-null assertion "!" and "=" together.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-confusing-void-expression": { - "create": [Function], - "defaultOptions": [ - { - "ignoreArrowShorthand": false, - "ignoreVoidOperator": false, - }, - ], - "meta": { - "docs": { - "description": "Require expressions of type void to appear in statement position", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-confusing-void-expression", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "invalidVoidExpr": "Placing a void expression inside another expression is forbidden. Move it to its own statement instead.", - "invalidVoidExprArrow": "Returning a void expression from an arrow function shorthand is forbidden. Please add braces to the arrow function.", - "invalidVoidExprArrowWrapVoid": "Void expressions returned from an arrow function shorthand must be marked explicitly with the \`void\` operator.", - "invalidVoidExprReturn": "Returning a void expression from a function is forbidden. Please move it before the \`return\` statement.", - "invalidVoidExprReturnLast": "Returning a void expression from a function is forbidden. Please remove the \`return\` statement.", - "invalidVoidExprReturnWrapVoid": "Void expressions returned from a function must be marked explicitly with the \`void\` operator.", - "invalidVoidExprWrapVoid": "Void expressions used inside another expression must be moved to its own statement or marked explicitly with the \`void\` operator.", - "voidExprWrapVoid": "Mark with an explicit \`void\` operator.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreArrowShorthand": { - "type": "boolean", - }, - "ignoreVoidOperator": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-dupe-class-members": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow duplicate class members", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-dupe-class-members", - }, - "hasSuggestions": undefined, - "messages": { - "unexpected": "Duplicate name '{{name}}'.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-duplicate-enum-values": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow duplicate enum member values", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-duplicate-enum-values", - }, - "hasSuggestions": false, - "messages": { - "duplicateValue": "Duplicate enum member value {{value}}.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-duplicate-type-constituents": { - "create": [Function], - "defaultOptions": [ - { - "ignoreIntersections": false, - "ignoreUnions": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow duplicate constituents of union or intersection types", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-duplicate-type-constituents", - }, - "fixable": "code", - "messages": { - "duplicate": "{{type}} type constituent is duplicated with {{previous}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreIntersections": { - "type": "boolean", - }, - "ignoreUnions": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-dynamic-delete": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow using the \`delete\` operator on computed key expressions", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-dynamic-delete", - }, - "fixable": "code", - "messages": { - "dynamicDelete": "Do not delete dynamically computed property keys.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-empty-function": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - }, - ], - "meta": { - "docs": { - "description": "Disallow empty functions", - "extendsBaseRule": true, - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/no-empty-function", - }, - "hasSuggestions": undefined, - "messages": { - "unexpected": "Unexpected empty {{name}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "enum": [ - "functions", - "arrowFunctions", - "generatorFunctions", - "methods", - "generatorMethods", - "getters", - "setters", - "constructors", - "private-constructors", - "protected-constructors", - "asyncFunctions", - "asyncMethods", - "decoratedFunctions", - "overrideMethods", - ], - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-empty-interface": { - "create": [Function], - "defaultOptions": [ - { - "allowSingleExtends": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow the declaration of empty interfaces", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/no-empty-interface", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "noEmpty": "An empty interface is equivalent to \`{}\`.", - "noEmptyWithSuper": "An interface declaring no members is equivalent to its supertype.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowSingleExtends": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-explicit-any": { - "create": [Function], - "defaultOptions": [ - { - "fixToUnknown": false, - "ignoreRestArgs": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow the \`any\` type", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-explicit-any", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "suggestNever": "Use \`never\` instead, this is useful when instantiating generic type parameters that you don't need to know the type of.", - "suggestUnknown": "Use \`unknown\` instead, this will force you to explicitly, and safely assert the type is correct.", - "unexpectedAny": "Unexpected any. Specify a different type.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "fixToUnknown": { - "description": "Whether to enable auto-fixing in which the \`any\` type is converted to the \`unknown\` type.", - "type": "boolean", - }, - "ignoreRestArgs": { - "description": "Whether to ignore rest parameter arrays.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-extra-non-null-assertion": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow extra non-null assertions", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-extra-non-null-assertion", - }, - "fixable": "code", - "messages": { - "noExtraNonNullAssertion": "Forbidden extra non-null assertion.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-extra-parens": { - "create": [Function], - "defaultOptions": [ - "all", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow unnecessary parentheses", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-extra-parens", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "unexpected": "Unnecessary parentheses around expression.", - }, - "replacedBy": [ - "@stylistic/ts/no-extra-parens", - ], - "schema": { - "anyOf": [ - { - "items": [ - { - "enum": [ - "functions", - ], - }, - ], - "maxItems": 1, - "minItems": 0, - "type": "array", - }, - { - "items": [ - { - "enum": [ - "all", - ], - }, - { - "additionalProperties": false, - "properties": { - "allowParensAfterCommentPattern": { - "type": "string", - }, - "conditionalAssign": { - "type": "boolean", - }, - "enforceForArrowConditionals": { - "type": "boolean", - }, - "enforceForFunctionPrototypeMethods": { - "type": "boolean", - }, - "enforceForNewInMemberExpressions": { - "type": "boolean", - }, - "enforceForSequenceExpressions": { - "type": "boolean", - }, - "ignoreJSX": { - "enum": [ - "none", - "all", - "single-line", - "multi-line", - ], - }, - "nestedBinaryExpressions": { - "type": "boolean", - }, - "returnAssign": { - "type": "boolean", - }, - "ternaryOperandBinaryExpressions": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - ], - }, - "type": "layout", - }, - }, - "no-extra-semi": { - "create": [Function], - "defaultOptions": [], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow unnecessary semicolons", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-extra-semi", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "unexpected": "Unnecessary semicolon.", - }, - "replacedBy": [ - "@stylistic/ts/no-extra-semi", - ], - "schema": [], - "type": "suggestion", - }, - }, - "no-extraneous-class": { - "create": [Function], - "defaultOptions": [ - { - "allowConstructorOnly": false, - "allowEmpty": false, - "allowStaticOnly": false, - "allowWithDecorator": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow classes used as namespaces", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-extraneous-class", - }, - "messages": { - "empty": "Unexpected empty class.", - "onlyConstructor": "Unexpected class with only a constructor.", - "onlyStatic": "Unexpected class with only static properties.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowConstructorOnly": { - "description": "Whether to allow extraneous classes that contain only a constructor.", - "type": "boolean", - }, - "allowEmpty": { - "description": "Whether to allow extraneous classes that have no body (i.e. are empty).", - "type": "boolean", - }, - "allowStaticOnly": { - "description": "Whether to allow extraneous classes that only contain static members.", - "type": "boolean", - }, - "allowWithDecorator": { - "description": "Whether to allow extraneous classes that include a decorator.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-floating-promises": { - "create": [Function], - "defaultOptions": [ - { - "ignoreIIFE": false, - "ignoreVoid": true, - }, - ], - "meta": { - "docs": { - "description": "Require Promise-like statements to be handled appropriately", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-floating-promises", - }, - "hasSuggestions": true, - "messages": { - "floating": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler.", - "floatingFixAwait": "Add await operator.", - "floatingFixVoid": "Add void operator to ignore.", - "floatingPromiseArray": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar.", - "floatingPromiseArrayVoid": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar, or explicitly marking the expression as ignored with the \`void\` operator.", - "floatingUselessRejectionHandler": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler. A rejection handler that is not a function will be ignored.", - "floatingUselessRejectionHandlerVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator. A rejection handler that is not a function will be ignored.", - "floatingVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreIIFE": { - "description": "Whether to ignore async IIFEs (Immediately Invoked Function Expressions).", - "type": "boolean", - }, - "ignoreVoid": { - "description": "Whether to ignore \`void\` expressions.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-for-in-array": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow iterating over an array with a for-in loop", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-for-in-array", - }, - "messages": { - "forInViolation": "For-in loops over arrays skips holes, returns indices as strings, and may visit the prototype chain or other enumerable properties. Use a more robust iteration method such as for-of or array.forEach instead.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-implied-eval": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow the use of \`eval()\`-like methods", - "extendsBaseRule": true, - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-implied-eval", - }, - "messages": { - "noFunctionConstructor": "Implied eval. Do not use the Function constructor to create functions.", - "noImpliedEvalError": "Implied eval. Consider passing a function.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-import-type-side-effects": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce the use of top-level import type qualifier when an import only has specifiers with inline type qualifiers", - "url": "https://typescript-eslint.io/rules/no-import-type-side-effects", - }, - "fixable": "code", - "messages": { - "useTopLevelQualifier": "TypeScript will only remove the inline type specifiers which will leave behind a side effect import at runtime. Convert this to a top-level type qualifier to properly remove the entire import.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-inferrable-types": { - "create": [Function], - "defaultOptions": [ - { - "ignoreParameters": false, - "ignoreProperties": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow explicit type declarations for variables or parameters initialized to a number, string, or boolean", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/no-inferrable-types", - }, - "fixable": "code", - "messages": { - "noInferrableType": "Type {{type}} trivially inferred from a {{type}} literal, remove type annotation.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreParameters": { - "type": "boolean", - }, - "ignoreProperties": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-invalid-this": { - "create": [Function], - "defaultOptions": [ - { - "capIsConstructor": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow \`this\` keywords outside of classes or class-like objects", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-invalid-this", - }, - "hasSuggestions": undefined, - "messages": { - "unexpectedThis": "Unexpected 'this'.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "capIsConstructor": { - "default": true, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-invalid-void-type": { - "create": [Function], - "defaultOptions": [ - { - "allowAsThisParameter": false, - "allowInGenericTypeArguments": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow \`void\` type outside of generic or return types", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-invalid-void-type", - }, - "messages": { - "invalidVoidForGeneric": "{{ generic }} may not have void as a type argument.", - "invalidVoidNotReturn": "void is only valid as a return type.", - "invalidVoidNotReturnOrGeneric": "void is only valid as a return type or generic type argument.", - "invalidVoidNotReturnOrThisParam": "void is only valid as return type or type of \`this\` parameter.", - "invalidVoidNotReturnOrThisParamOrGeneric": "void is only valid as a return type or generic type argument or the type of a \`this\` parameter.", - "invalidVoidUnionConstituent": "void is not valid as a constituent in a union type", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAsThisParameter": { - "type": "boolean", - }, - "allowInGenericTypeArguments": { - "oneOf": [ - { - "type": "boolean", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-loop-func": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow function declarations that contain unsafe references inside loop statements", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-loop-func", - }, - "hasSuggestions": undefined, - "messages": { - "unsafeRefs": "Function declared in a loop contains unsafe references to variable(s) {{ varNames }}.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-loss-of-precision": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow literal numbers that lose precision", - "extendsBaseRule": true, - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-loss-of-precision", - }, - "hasSuggestions": undefined, - "messages": { - "noLossOfPrecision": "This number literal will lose precision at runtime.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-magic-numbers": { - "create": [Function], - "defaultOptions": [ - { - "detectObjects": false, - "enforceConst": false, - "ignore": [], - "ignoreArrayIndexes": false, - "ignoreEnums": false, - "ignoreNumericLiteralTypes": false, - "ignoreReadonlyClassProperties": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow magic numbers", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-magic-numbers", - }, - "messages": { - "noMagic": "No magic number: {{raw}}.", - "useConst": "Number constants declarations must use 'const'.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "detectObjects": { - "default": false, - "type": "boolean", - }, - "enforceConst": { - "default": false, - "type": "boolean", - }, - "ignore": { - "items": { - "anyOf": [ - { - "type": "number", - }, - { - "pattern": "^[+-]?(?:0|[1-9][0-9]*)n$", - "type": "string", - }, - ], - }, - "type": "array", - "uniqueItems": true, - }, - "ignoreArrayIndexes": { - "default": false, - "type": "boolean", - }, - "ignoreClassFieldInitialValues": { - "default": false, - "type": "boolean", - }, - "ignoreDefaultValues": { - "default": false, - "type": "boolean", - }, - "ignoreEnums": { - "type": "boolean", - }, - "ignoreNumericLiteralTypes": { - "type": "boolean", - }, - "ignoreReadonlyClassProperties": { - "type": "boolean", - }, - "ignoreTypeIndexes": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-meaningless-void-operator": { - "create": [Function], - "defaultOptions": [ - { - "checkNever": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow the \`void\` operator except when used to discard a value", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-meaningless-void-operator", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "meaninglessVoidOperator": "void operator shouldn't be used on {{type}}; it should convey that a return value is being ignored", - "removeVoid": "Remove 'void'", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "checkNever": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-misused-new": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce valid definition of \`new\` and \`constructor\`", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-misused-new", - }, - "messages": { - "errorMessageClass": "Class cannot have method named \`new\`.", - "errorMessageInterface": "Interfaces cannot be constructed, only classes.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-misused-promises": { - "create": [Function], - "defaultOptions": [ - { - "checksConditionals": true, - "checksSpreads": true, - "checksVoidReturn": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow Promises in places not designed to handle them", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-misused-promises", - }, - "messages": { - "conditional": "Expected non-Promise value in a boolean conditional.", - "spread": "Expected a non-Promise value to be spreaded in an object.", - "voidReturnArgument": "Promise returned in function argument where a void return was expected.", - "voidReturnAttribute": "Promise-returning function provided to attribute where a void return was expected.", - "voidReturnProperty": "Promise-returning function provided to property where a void return was expected.", - "voidReturnReturnValue": "Promise-returning function provided to return value where a void return was expected.", - "voidReturnVariable": "Promise-returning function provided to variable where a void return was expected.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "checksConditionals": { - "type": "boolean", - }, - "checksSpreads": { - "type": "boolean", - }, - "checksVoidReturn": { - "oneOf": [ - { - "type": "boolean", - }, - { - "additionalProperties": false, - "properties": { - "arguments": { - "type": "boolean", - }, - "attributes": { - "type": "boolean", - }, - "properties": { - "type": "boolean", - }, - "returns": { - "type": "boolean", - }, - "variables": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-mixed-enums": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow enums from having both number and string members", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-mixed-enums", - }, - "messages": { - "mixed": "Mixing number and string enums can be confusing.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-namespace": { - "create": [Function], - "defaultOptions": [ - { - "allowDeclarations": false, - "allowDefinitionFiles": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow TypeScript namespaces", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-namespace", - }, - "messages": { - "moduleSyntaxIsPreferred": "ES2015 module syntax is preferred over namespaces.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowDeclarations": { - "description": "Whether to allow \`declare\` with custom TypeScript namespaces.", - "type": "boolean", - }, - "allowDefinitionFiles": { - "description": "Whether to allow \`declare\` with custom TypeScript namespaces inside definition files.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-non-null-asserted-nullish-coalescing": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow non-null assertions in the left operand of a nullish coalescing operator", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-non-null-asserted-nullish-coalescing", - }, - "hasSuggestions": true, - "messages": { - "noNonNullAssertedNullishCoalescing": "The nullish coalescing operator is designed to handle undefined and null - using a non-null assertion is not needed.", - "suggestRemovingNonNull": "Remove the non-null assertion.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-non-null-asserted-optional-chain": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow non-null assertions after an optional chain expression", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-non-null-asserted-optional-chain", - }, - "hasSuggestions": true, - "messages": { - "noNonNullOptionalChain": "Optional chain expressions can return undefined by design - using a non-null assertion is unsafe and wrong.", - "suggestRemovingNonNull": "You should remove the non-null assertion.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-non-null-assertion": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow non-null assertions using the \`!\` postfix operator", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-non-null-assertion", - }, - "hasSuggestions": true, - "messages": { - "noNonNull": "Forbidden non-null assertion.", - "suggestOptionalChain": "Consider using the optional chain operator \`?.\` instead. This operator includes runtime checks, so it is safer than the compile-only non-null assertion operator.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-redeclare": { - "create": [Function], - "defaultOptions": [ - { - "builtinGlobals": true, - "ignoreDeclarationMerge": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow variable redeclaration", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-redeclare", - }, - "messages": { - "redeclared": "'{{id}}' is already defined.", - "redeclaredAsBuiltin": "'{{id}}' is already defined as a built-in global variable.", - "redeclaredBySyntax": "'{{id}}' is already defined by a variable declaration.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "builtinGlobals": { - "type": "boolean", - }, - "ignoreDeclarationMerge": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-redundant-type-constituents": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow members of unions and intersections that do nothing or override type information", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-redundant-type-constituents", - }, - "messages": { - "literalOverridden": "{{literal}} is overridden by {{primitive}} in this union type.", - "overridden": "'{{typeName}}' is overridden by other types in this {{container}} type.", - "overrides": "'{{typeName}}' overrides all other types in this {{container}} type.", - "primitiveOverridden": "{{primitive}} is overridden by the {{literal}} in this intersection type.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-require-imports": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - }, - ], - "meta": { - "docs": { - "description": "Disallow invocation of \`require()\`", - "url": "https://typescript-eslint.io/rules/no-require-imports", - }, - "messages": { - "noRequireImports": "A \`require()\` style import is forbidden.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "description": "Patterns of import paths to allow requiring from.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-restricted-imports": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow specified modules when loaded by \`import\`", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-restricted-imports", - }, - "fixable": undefined, - "messages": { - "everything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted.", - "everythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted. {{customMessage}}", - "importName": "'{{importName}}' import from '{{importSource}}' is restricted.", - "importNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted. {{customMessage}}", - "path": "'{{importSource}}' import is restricted from being used.", - "pathWithCustomMessage": "'{{importSource}}' import is restricted from being used. {{customMessage}}", - "patternAndEverything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern.", - "patternAndEverythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", - "patternAndEverythingWithRegexImportName": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used.", - "patternAndEverythingWithRegexImportNameAndCustomMessage": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used. {{customMessage}}", - "patternAndImportName": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern.", - "patternAndImportNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", - "patternWithCustomMessage": "'{{importSource}}' import is restricted from being used by a pattern. {{customMessage}}", - "patterns": "'{{importSource}}' import is restricted from being used by a pattern.", - }, - "schema": { - "anyOf": [ - { - "items": { - "anyOf": [ - { - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "allowTypeImports": { - "description": "Disallow value imports, but allow type-only imports.", - "type": "boolean", - }, - "importNames": { - "items": { - "type": "string", - }, - "type": "array", - }, - "message": { - "minLength": 1, - "type": "string", - }, - "name": { - "type": "string", - }, - }, - "required": [ - "name", - ], - "type": "object", - }, - ], - }, - "type": "array", - "uniqueItems": true, - }, - { - "additionalItems": false, - "items": [ - { - "additionalProperties": false, - "properties": { - "paths": { - "items": { - "anyOf": [ - { - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "allowTypeImports": { - "description": "Disallow value imports, but allow type-only imports.", - "type": "boolean", - }, - "importNames": { - "items": { - "type": "string", - }, - "type": "array", - }, - "message": { - "minLength": 1, - "type": "string", - }, - "name": { - "type": "string", - }, - }, - "required": [ - "name", - ], - "type": "object", - }, - ], - }, - "type": "array", - "uniqueItems": true, - }, - "patterns": { - "anyOf": [ - { - "items": { - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - { - "items": { - "additionalProperties": false, - "properties": { - "allowTypeImports": { - "description": "Disallow value imports, but allow type-only imports.", - "type": "boolean", - }, - "caseSensitive": { - "type": "boolean", - }, - "group": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - "importNamePattern": { - "type": "string", - }, - "importNames": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - "message": { - "minLength": 1, - "type": "string", - }, - }, - "required": [ - "group", - ], - "type": "object", - }, - "type": "array", - "uniqueItems": true, - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "array", - }, - ], - }, - "type": "suggestion", - }, - }, - "no-shadow": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - "builtinGlobals": false, - "hoist": "functions", - "ignoreFunctionTypeParameterNameValueShadow": true, - "ignoreOnInitialization": false, - "ignoreTypeValueShadow": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow variable declarations from shadowing variables declared in the outer scope", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-shadow", - }, - "messages": { - "noShadow": "'{{name}}' is already declared in the upper scope on line {{shadowedLine}} column {{shadowedColumn}}.", - "noShadowGlobal": "'{{name}}' is already a global variable.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "type": "string", - }, - "type": "array", - }, - "builtinGlobals": { - "type": "boolean", - }, - "hoist": { - "enum": [ - "all", - "functions", - "never", - ], - "type": "string", - }, - "ignoreFunctionTypeParameterNameValueShadow": { - "type": "boolean", - }, - "ignoreOnInitialization": { - "type": "boolean", - }, - "ignoreTypeValueShadow": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-this-alias": { - "create": [Function], - "defaultOptions": [ - { - "allowDestructuring": true, - "allowedNames": [], - }, - ], - "meta": { - "docs": { - "description": "Disallow aliasing \`this\`", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-this-alias", - }, - "messages": { - "thisAssignment": "Unexpected aliasing of 'this' to local variable.", - "thisDestructure": "Unexpected aliasing of members of 'this' to local variables.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowDestructuring": { - "description": "Whether to ignore destructurings, such as \`const { props, state } = this\`.", - "type": "boolean", - }, - "allowedNames": { - "description": "Names to ignore, such as ["self"] for \`const self = this;\`.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-throw-literal": { - "create": [Function], - "defaultOptions": [ - { - "allowThrowingAny": true, - "allowThrowingUnknown": true, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow throwing literals as exceptions", - "extendsBaseRule": true, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-throw-literal", - }, - "messages": { - "object": "Expected an error object to be thrown.", - "undef": "Do not throw undefined.", - }, - "replacedBy": [ - "@typescript-eslint/only-throw-error", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowThrowingAny": { - "type": "boolean", - }, - "allowThrowingUnknown": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-type-alias": { - "create": [Function], - "defaultOptions": [ - { - "allowAliases": "never", - "allowCallbacks": "never", - "allowConditionalTypes": "never", - "allowConstructors": "never", - "allowGenerics": "never", - "allowLiterals": "never", - "allowMappedTypes": "never", - "allowTupleTypes": "never", - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow type aliases", - "url": "https://typescript-eslint.io/rules/no-type-alias", - }, - "messages": { - "noCompositionAlias": "{{typeName}} in {{compositionType}} types are not allowed.", - "noTypeAlias": "Type {{alias}} are not allowed.", - }, - "schema": [ - { - "$defs": { - "expandedOptions": { - "enum": [ - "always", - "never", - "in-unions", - "in-intersections", - "in-unions-and-intersections", - ], - "type": "string", - }, - "simpleOptions": { - "enum": [ - "always", - "never", - ], - "type": "string", - }, - }, - "additionalProperties": false, - "properties": { - "allowAliases": { - "$ref": "#/items/0/$defs/expandedOptions", - "description": "Whether to allow direct one-to-one type aliases.", - }, - "allowCallbacks": { - "$ref": "#/items/0/$defs/simpleOptions", - "description": "Whether to allow type aliases for callbacks.", - }, - "allowConditionalTypes": { - "$ref": "#/items/0/$defs/simpleOptions", - "description": "Whether to allow type aliases for conditional types.", - }, - "allowConstructors": { - "$ref": "#/items/0/$defs/simpleOptions", - "description": "Whether to allow type aliases with constructors.", - }, - "allowGenerics": { - "$ref": "#/items/0/$defs/simpleOptions", - "description": "Whether to allow type aliases with generic types.", - }, - "allowLiterals": { - "$ref": "#/items/0/$defs/expandedOptions", - "description": "Whether to allow type aliases with object literal types.", - }, - "allowMappedTypes": { - "$ref": "#/items/0/$defs/expandedOptions", - "description": "Whether to allow type aliases with mapped types.", - }, - "allowTupleTypes": { - "$ref": "#/items/0/$defs/expandedOptions", - "description": "Whether to allow type aliases with tuple types.", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unnecessary-boolean-literal-compare": { - "create": [Function], - "defaultOptions": [ - { - "allowComparingNullableBooleansToFalse": true, - "allowComparingNullableBooleansToTrue": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow unnecessary equality comparisons against boolean literals", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-boolean-literal-compare", - }, - "fixable": "code", - "messages": { - "comparingNullableToFalse": "This expression unnecessarily compares a nullable boolean value to false instead of using the ?? operator to provide a default.", - "comparingNullableToTrueDirect": "This expression unnecessarily compares a nullable boolean value to true instead of using it directly.", - "comparingNullableToTrueNegated": "This expression unnecessarily compares a nullable boolean value to true instead of negating it.", - "direct": "This expression unnecessarily compares a boolean value to a boolean instead of using it directly.", - "negated": "This expression unnecessarily compares a boolean value to a boolean instead of negating it.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowComparingNullableBooleansToFalse": { - "description": "Whether to allow comparisons between nullable boolean variables and \`false\`.", - "type": "boolean", - }, - "allowComparingNullableBooleansToTrue": { - "description": "Whether to allow comparisons between nullable boolean variables and \`true\`.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unnecessary-condition": { - "create": [Function], - "defaultOptions": [ - { - "allowConstantLoopConditions": false, - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow conditionals where the type is always truthy or always falsy", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-condition", - }, - "fixable": "code", - "messages": { - "alwaysFalsy": "Unnecessary conditional, value is always falsy.", - "alwaysFalsyFunc": "This callback should return a conditional, but return is always falsy.", - "alwaysNullish": "Unnecessary conditional, left-hand side of \`??\` operator is always \`null\` or \`undefined\`.", - "alwaysTruthy": "Unnecessary conditional, value is always truthy.", - "alwaysTruthyFunc": "This callback should return a conditional, but return is always truthy.", - "literalBooleanExpression": "Unnecessary conditional, both sides of the expression are literal values.", - "never": "Unnecessary conditional, value is \`never\`.", - "neverNullish": "Unnecessary conditional, expected left-hand side of \`??\` operator to be possibly null or undefined.", - "neverOptionalChain": "Unnecessary optional chain on a non-nullish value.", - "noOverlapBooleanExpression": "Unnecessary conditional, the types have no overlap.", - "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowConstantLoopConditions": { - "description": "Whether to ignore constant loop conditions, such as \`while (true)\`.", - "type": "boolean", - }, - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { - "description": "Whether to not error when running with a tsconfig that has strictNullChecks turned.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unnecessary-qualifier": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unnecessary namespace qualifiers", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-qualifier", - }, - "fixable": "code", - "messages": { - "unnecessaryQualifier": "Qualifier is unnecessary since '{{ name }}' is in scope.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-unnecessary-type-arguments": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow type arguments that are equal to the default", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-type-arguments", - }, - "fixable": "code", - "messages": { - "unnecessaryTypeParameter": "This is the default value for this type parameter, so it can be omitted.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-unnecessary-type-assertion": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "docs": { - "description": "Disallow type assertions that do not change the type of an expression", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-type-assertion", - }, - "fixable": "code", - "messages": { - "contextuallyUnnecessary": "This assertion is unnecessary since the receiver accepts the original type of the expression.", - "unnecessaryAssertion": "This assertion is unnecessary since it does not change the type of the expression.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "typesToIgnore": { - "description": "A list of type names to ignore.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unnecessary-type-constraint": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unnecessary constraints on generic types", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-unnecessary-type-constraint", - }, - "hasSuggestions": true, - "messages": { - "removeUnnecessaryConstraint": "Remove the unnecessary \`{{constraint}}\` constraint.", - "unnecessaryConstraint": "Constraining the generic type \`{{name}}\` to \`{{constraint}}\` does nothing and is unnecessary.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-unsafe-argument": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow calling a function with a value with type \`any\`", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-argument", - }, - "messages": { - "unsafeArgument": "Unsafe argument of type \`{{sender}}\` assigned to a parameter of type \`{{receiver}}\`.", - "unsafeArraySpread": "Unsafe spread of an \`any\` array type.", - "unsafeSpread": "Unsafe spread of an \`any\` type.", - "unsafeTupleSpread": "Unsafe spread of a tuple type. The argument is of type \`{{sender}}\` and is assigned to a parameter of type \`{{receiver}}\`.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-assignment": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow assigning a value with type \`any\` to variables and properties", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-assignment", - }, - "messages": { - "anyAssignment": "Unsafe assignment of an \`any\` value.", - "anyAssignmentThis": "Unsafe assignment of an \`any\` value. \`this\` is typed as \`any\`. -You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", - "unsafeArrayPattern": "Unsafe array destructuring of an \`any\` array value.", - "unsafeArrayPatternFromTuple": "Unsafe array destructuring of a tuple element with an \`any\` value.", - "unsafeArraySpread": "Unsafe spread of an \`any\` value in an array.", - "unsafeAssignment": "Unsafe assignment of type {{sender}} to a variable of type {{receiver}}.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-call": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow calling a value with type \`any\`", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-call", - }, - "messages": { - "unsafeCall": "Unsafe call of an \`any\` typed value.", - "unsafeCallThis": "Unsafe call of an \`any\` typed value. \`this\` is typed as \`any\`. -You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", - "unsafeNew": "Unsafe construction of an any type value.", - "unsafeTemplateTag": "Unsafe any typed template tag.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-declaration-merging": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unsafe declaration merging", - "recommended": "recommended", - "requiresTypeChecking": false, - "url": "https://typescript-eslint.io/rules/no-unsafe-declaration-merging", - }, - "messages": { - "unsafeMerging": "Unsafe declaration merging between classes and interfaces.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-enum-comparison": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow comparing an enum value with a non-enum value", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-enum-comparison", - }, - "hasSuggestions": true, - "messages": { - "mismatchedCase": "The case statement does not have a shared enum type with the switch predicate.", - "mismatchedCondition": "The two values in this comparison do not have a shared enum type.", - "replaceValueWithEnum": "Replace with an enum value comparison.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-unsafe-member-access": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow member access on a value with type \`any\`", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-member-access", - }, - "messages": { - "unsafeComputedMemberAccess": "Computed name {{property}} resolves to an any value.", - "unsafeMemberExpression": "Unsafe member access {{property}} on an \`any\` value.", - "unsafeThisMemberExpression": "Unsafe member access {{property}} on an \`any\` value. \`this\` is typed as \`any\`. -You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-return": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow returning a value with type \`any\` from a function", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-return", - }, - "messages": { - "unsafeReturn": "Unsafe return of an \`{{type}}\` typed value.", - "unsafeReturnAssignment": "Unsafe return of type \`{{sender}}\` from function with return type \`{{receiver}}\`.", - "unsafeReturnThis": "Unsafe return of an \`{{type}}\` typed value. \`this\` is typed as \`any\`. -You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-unary-minus": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Require unary negation to take a number", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-unary-minus", - }, - "messages": { - "unaryMinus": "Argument of unary negation should be assignable to number | bigint but is {{type}} instead.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unused-expressions": { - "create": [Function], - "defaultOptions": [ - { - "allowShortCircuit": false, - "allowTaggedTemplates": false, - "allowTernary": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow unused expressions", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-unused-expressions", - }, - "hasSuggestions": undefined, - "messages": { - "unusedExpression": "Expected an assignment or function call and instead saw an expression.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowShortCircuit": { - "default": false, - "type": "boolean", - }, - "allowTaggedTemplates": { - "default": false, - "type": "boolean", - }, - "allowTernary": { - "default": false, - "type": "boolean", - }, - "enforceForJSX": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unused-vars": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "docs": { - "description": "Disallow unused variables", - "extendsBaseRule": true, - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-unused-vars", - }, - "messages": { - "unusedVar": "'{{varName}}' is {{action}} but never used{{additional}}.", - }, - "schema": [ - { - "oneOf": [ - { - "enum": [ - "all", - "local", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "args": { - "enum": [ - "all", - "after-used", - "none", - ], - "type": "string", - }, - "argsIgnorePattern": { - "type": "string", - }, - "caughtErrors": { - "enum": [ - "all", - "none", - ], - "type": "string", - }, - "caughtErrorsIgnorePattern": { - "type": "string", - }, - "destructuredArrayIgnorePattern": { - "type": "string", - }, - "ignoreRestSiblings": { - "type": "boolean", - }, - "vars": { - "enum": [ - "all", - "local", - ], - "type": "string", - }, - "varsIgnorePattern": { - "type": "string", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "problem", - }, - }, - "no-use-before-define": { - "create": [Function], - "defaultOptions": [ - { - "allowNamedExports": false, - "classes": true, - "enums": true, - "functions": true, - "ignoreTypeReferences": true, - "typedefs": true, - "variables": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow the use of variables before they are defined", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-use-before-define", - }, - "messages": { - "noUseBeforeDefine": "'{{name}}' was used before it was defined.", - }, - "schema": [ - { - "oneOf": [ - { - "enum": [ - "nofunc", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "allowNamedExports": { - "type": "boolean", - }, - "classes": { - "type": "boolean", - }, - "enums": { - "type": "boolean", - }, - "functions": { - "type": "boolean", - }, - "ignoreTypeReferences": { - "type": "boolean", - }, - "typedefs": { - "type": "boolean", - }, - "variables": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "problem", - }, - }, - "no-useless-constructor": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unnecessary constructors", - "extendsBaseRule": true, - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-useless-constructor", - }, - "hasSuggestions": undefined, - "messages": { - "noUselessConstructor": "Useless constructor.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-useless-empty-export": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow empty exports that don't change anything in a module file", - "url": "https://typescript-eslint.io/rules/no-useless-empty-export", - }, - "fixable": "code", - "hasSuggestions": false, - "messages": { - "uselessExport": "Empty export does nothing and can be removed.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-useless-template-literals": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unnecessary template literals", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-useless-template-literals", - }, - "fixable": "code", - "messages": { - "noUselessTemplateLiteral": "Template literal expression is unnecessary and can be simplified.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-var-requires": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - }, - ], - "meta": { - "docs": { - "description": "Disallow \`require\` statements except in import statements", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-var-requires", - }, - "messages": { - "noVarReqs": "Require statement not part of import statement.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "description": "Patterns of import paths to allow requiring from.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "non-nullable-type-assertion-style": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce non-null assertions over explicit type casts", - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/non-nullable-type-assertion-style", - }, - "fixable": "code", - "messages": { - "preferNonNullAssertion": "Use a ! assertion to more succinctly remove null and undefined from the type.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "object-curly-spacing": { - "create": [Function], - "defaultOptions": [ - "never", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing inside braces", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/object-curly-spacing", - }, - "fixable": "whitespace", - "messages": { - "requireSpaceAfter": "A space is required after '{{token}}'.", - "requireSpaceBefore": "A space is required before '{{token}}'.", - "unexpectedSpaceAfter": "There should be no space after '{{token}}'.", - "unexpectedSpaceBefore": "There should be no space before '{{token}}'.", - }, - "replacedBy": [ - "@stylistic/ts/object-curly-spacing", - ], - "schema": [ - { - "enum": [ - "always", - "never", - ], - }, - { - "additionalProperties": false, - "properties": { - "arraysInObjects": { - "type": "boolean", - }, - "objectsInObjects": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "only-throw-error": { - "create": [Function], - "defaultOptions": [ - { - "allowThrowingAny": true, - "allowThrowingUnknown": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow throwing non-\`Error\` values as exceptions", - "extendsBaseRule": "no-throw-literal", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/only-throw-error", - }, - "messages": { - "object": "Expected an error object to be thrown.", - "undef": "Do not throw undefined.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowThrowingAny": { - "type": "boolean", - }, - "allowThrowingUnknown": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "padding-line-between-statements": { - "create": [Function], - "defaultOptions": [], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow padding lines between statements", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/padding-line-between-statements", - }, - "fixable": "whitespace", - "hasSuggestions": false, - "messages": { - "expectedBlankLine": "Expected blank line before this statement.", - "unexpectedBlankLine": "Unexpected blank line before this statement.", - }, - "replacedBy": [ - "@stylistic/ts/padding-line-between-statements", - ], - "schema": { - "$defs": { - "paddingType": { - "enum": [ - "any", - "never", - "always", - ], - "type": "string", - }, - "statementType": { - "anyOf": [ - { - "enum": [ - "*", - "block-like", - "exports", - "require", - "directive", - "expression", - "iife", - "multiline-block-like", - "multiline-expression", - "multiline-const", - "multiline-let", - "multiline-var", - "singleline-const", - "singleline-let", - "singleline-var", - "block", - "empty", - "function", - "break", - "case", - "class", - "const", - "continue", - "debugger", - "default", - "do", - "export", - "for", - "if", - "import", - "let", - "return", - "switch", - "throw", - "try", - "var", - "while", - "with", - "interface", - "type", - ], - "type": "string", - }, - { - "additionalItems": false, - "items": { - "enum": [ - "*", - "block-like", - "exports", - "require", - "directive", - "expression", - "iife", - "multiline-block-like", - "multiline-expression", - "multiline-const", - "multiline-let", - "multiline-var", - "singleline-const", - "singleline-let", - "singleline-var", - "block", - "empty", - "function", - "break", - "case", - "class", - "const", - "continue", - "debugger", - "default", - "do", - "export", - "for", - "if", - "import", - "let", - "return", - "switch", - "throw", - "try", - "var", - "while", - "with", - "interface", - "type", - ], - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - }, - "additionalItems": false, - "items": { - "additionalProperties": false, - "properties": { - "blankLine": { - "$ref": "#/$defs/paddingType", - }, - "next": { - "$ref": "#/$defs/statementType", - }, - "prev": { - "$ref": "#/$defs/statementType", - }, - }, - "required": [ - "blankLine", - "prev", - "next", - ], - "type": "object", - }, - "type": "array", - }, - "type": "layout", - }, - }, - "parameter-properties": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - "prefer": "class-property", - }, - ], - "meta": { - "docs": { - "description": "Require or disallow parameter properties in class constructors", - "url": "https://typescript-eslint.io/rules/parameter-properties", - }, - "messages": { - "preferClassProperty": "Property {{parameter}} should be declared as a class property.", - "preferParameterProperty": "Property {{parameter}} should be declared as a parameter property.", - }, - "schema": [ - { - "$defs": { - "modifier": { - "enum": [ - "readonly", - "private", - "protected", - "public", - "private readonly", - "protected readonly", - "public readonly", - ], - "type": "string", - }, - }, - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "$ref": "#/items/0/$defs/modifier", - }, - "type": "array", - }, - "prefer": { - "enum": [ - "class-property", - "parameter-property", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "prefer-as-const": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce the use of \`as const\` over literal type", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/prefer-as-const", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "preferConstAssertion": "Expected a \`const\` instead of a literal type assertion.", - "variableConstAssertion": "Expected a \`const\` assertion instead of a literal type annotation.", - "variableSuggest": "You should use \`as const\` instead of type annotation.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-destructuring": { - "create": [Function], - "defaultOptions": [ - { - "AssignmentExpression": { - "array": true, - "object": true, - }, - "VariableDeclarator": { - "array": true, - "object": true, - }, - }, - {}, - ], - "meta": { - "docs": { - "description": "Require destructuring from arrays and/or objects", - "extendsBaseRule": true, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-destructuring", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "preferDestructuring": "Use {{type}} destructuring.", - }, - "schema": [ - { - "oneOf": [ - { - "additionalProperties": false, - "properties": { - "AssignmentExpression": { - "additionalProperties": false, - "properties": { - "array": { - "type": "boolean", - }, - "object": { - "type": "boolean", - }, - }, - "type": "object", - }, - "VariableDeclarator": { - "additionalProperties": false, - "properties": { - "array": { - "type": "boolean", - }, - "object": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "array": { - "type": "boolean", - }, - "object": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - }, - { - "properties": { - "enforceForDeclarationWithTypeAnnotation": { - "type": "boolean", - }, - "enforceForRenamedProperties": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-enum-initializers": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Require each enum member value to be explicitly initialized", - "url": "https://typescript-eslint.io/rules/prefer-enum-initializers", - }, - "hasSuggestions": true, - "messages": { - "defineInitializer": "The value of the member '{{ name }}' should be explicitly defined.", - "defineInitializerSuggestion": "Can be fixed to {{ name }} = {{ suggested }}", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-find": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce the use of Array.prototype.find() over Array.prototype.filter() followed by [0] when looking for a single result", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-find", - }, - "hasSuggestions": true, - "messages": { - "preferFind": "Prefer .find(...) instead of .filter(...)[0].", - "preferFindSuggestion": "Use .find(...) instead of .filter(...)[0].", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-for-of": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce the use of \`for-of\` loop over the standard \`for\` loop where possible", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/prefer-for-of", - }, - "messages": { - "preferForOf": "Expected a \`for-of\` loop instead of a \`for\` loop with this simple iteration.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-function-type": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce using function types instead of interfaces with call signatures", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/prefer-function-type", - }, - "fixable": "code", - "messages": { - "functionTypeOverCallableType": "{{ literalOrInterface }} only has a call signature, you should use a function type instead.", - "unexpectedThisOnFunctionOnlyInterface": "\`this\` refers to the function type '{{ interfaceName }}', did you intend to use a generic \`this\` parameter like \`(this: Self, ...) => Self\` instead?", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-includes": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce \`includes\` method over \`indexOf\` method", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-includes", - }, - "fixable": "code", - "messages": { - "preferIncludes": "Use 'includes()' method instead.", - "preferStringIncludes": "Use \`String#includes()\` method with a string instead.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-literal-enum-member": { - "create": [Function], - "defaultOptions": [ - { - "allowBitwiseExpressions": false, - }, - ], - "meta": { - "docs": { - "description": "Require all enum members to be literal values", - "recommended": "strict", - "requiresTypeChecking": false, - "url": "https://typescript-eslint.io/rules/prefer-literal-enum-member", - }, - "messages": { - "notLiteral": "Explicit enum value must only be a literal value (string, number, boolean, etc).", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowBitwiseExpressions": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-namespace-keyword": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Require using \`namespace\` keyword over \`module\` keyword to declare custom TypeScript modules", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/prefer-namespace-keyword", - }, - "fixable": "code", - "messages": { - "useNamespace": "Use 'namespace' instead of 'module' to declare custom TypeScript modules.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-nullish-coalescing": { - "create": [Function], - "defaultOptions": [ - { - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, - "ignoreConditionalTests": false, - "ignoreMixedLogicalExpressions": false, - "ignorePrimitives": { - "bigint": false, - "boolean": false, - "number": false, - "string": false, - }, - "ignoreTernaryTests": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce using the nullish coalescing operator instead of logical assignments or chaining", - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-nullish-coalescing", - }, - "hasSuggestions": true, - "messages": { - "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", - "preferNullishOverOr": "Prefer using nullish coalescing operator (\`??\`) instead of a logical or (\`||\`), as it is a safer operator.", - "preferNullishOverTernary": "Prefer using nullish coalescing operator (\`??\`) instead of a ternary expression, as it is simpler to read.", - "suggestNullish": "Fix to nullish coalescing operator (\`??\`).", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { - "type": "boolean", - }, - "ignoreConditionalTests": { - "type": "boolean", - }, - "ignoreMixedLogicalExpressions": { - "type": "boolean", - }, - "ignorePrimitives": { - "oneOf": [ - { - "properties": { - "bigint": { - "type": "boolean", - }, - "boolean": { - "type": "boolean", - }, - "number": { - "type": "boolean", - }, - "string": { - "type": "boolean", - }, - }, - "type": "object", - }, - { - "enum": [ - true, - ], - "type": "boolean", - }, - ], - }, - "ignoreTernaryTests": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-optional-chain": { - "create": [Function], - "defaultOptions": [ - { - "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": false, - "checkAny": true, - "checkBigInt": true, - "checkBoolean": true, - "checkNumber": true, - "checkString": true, - "checkUnknown": true, - "requireNullish": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce using concise optional chain expressions instead of chained logical ands, negated logical ors, or empty objects", - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-optional-chain", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "optionalChainSuggest": "Change to an optional chain.", - "preferOptionalChain": "Prefer using an optional chain expression instead, as it's more concise and easier to read.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": { - "description": "Allow autofixers that will change the return type of the expression. This option is considered unsafe as it may break the build.", - "type": "boolean", - }, - "checkAny": { - "description": "Check operands that are typed as \`any\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkBigInt": { - "description": "Check operands that are typed as \`bigint\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkBoolean": { - "description": "Check operands that are typed as \`boolean\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkNumber": { - "description": "Check operands that are typed as \`number\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkString": { - "description": "Check operands that are typed as \`string\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkUnknown": { - "description": "Check operands that are typed as \`unknown\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "requireNullish": { - "description": "Skip operands that are not typed with \`null\` and/or \`undefined\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-promise-reject-errors": { - "create": [Function], - "defaultOptions": [ - { - "allowEmptyReject": false, - }, - ], - "meta": { - "docs": { - "description": "Require using Error objects as Promise rejection reasons", - "extendsBaseRule": true, - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-promise-reject-errors", - }, - "messages": { - "rejectAnError": "Expected the Promise rejection reason to be an Error.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowEmptyReject": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-readonly": { - "create": [Function], - "defaultOptions": [ - { - "onlyInlineLambdas": false, - }, - ], - "meta": { - "docs": { - "description": "Require private members to be marked as \`readonly\` if they're never modified outside of the constructor", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-readonly", - }, - "fixable": "code", - "messages": { - "preferReadonly": "Member '{{name}}' is never reassigned; mark it as \`readonly\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "onlyInlineLambdas": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-readonly-parameter-types": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - "checkParameterProperties": true, - "ignoreInferredTypes": false, - "treatMethodsAsReadonly": false, - }, - ], - "meta": { - "docs": { - "description": "Require function parameters to be typed as \`readonly\` to prevent accidental mutation of inputs", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-readonly-parameter-types", - }, - "messages": { - "shouldBeReadonly": "Parameter should be a read only type.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "oneOf": [ - { - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "from": { - "enum": [ - "file", - ], - "type": "string", - }, - "name": { - "oneOf": [ - { - "type": "string", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - "path": { - "type": "string", - }, - }, - "required": [ - "from", - "name", - ], - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "from": { - "enum": [ - "lib", - ], - "type": "string", - }, - "name": { - "oneOf": [ - { - "type": "string", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - }, - "required": [ - "from", - "name", - ], - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "from": { - "enum": [ - "package", - ], - "type": "string", - }, - "name": { - "oneOf": [ - { - "type": "string", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - "package": { - "type": "string", - }, - }, - "required": [ - "from", - "name", - "package", - ], - "type": "object", - }, - ], - }, - "type": "array", - }, - "checkParameterProperties": { - "type": "boolean", - }, - "ignoreInferredTypes": { - "type": "boolean", - }, - "treatMethodsAsReadonly": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-reduce-type-parameter": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce using type parameter when calling \`Array#reduce\` instead of casting", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-reduce-type-parameter", - }, - "fixable": "code", - "messages": { - "preferTypeParameter": "Unnecessary cast: Array#reduce accepts a type parameter for the default value.", - }, - "schema": [], - "type": "problem", - }, - }, - "prefer-regexp-exec": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce \`RegExp#exec\` over \`String#match\` if no global flag is provided", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-regexp-exec", - }, - "fixable": "code", - "messages": { - "regExpExecOverStringMatch": "Use the \`RegExp#exec()\` method instead.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-return-this-type": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce that \`this\` is used when only \`this\` type is returned", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-return-this-type", - }, - "fixable": "code", - "messages": { - "useThisType": "Use \`this\` type instead.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-string-starts-ends-with": { - "create": [Function], - "defaultOptions": [ - { - "allowSingleElementEquality": "never", - }, - ], - "meta": { - "docs": { - "description": "Enforce using \`String#startsWith\` and \`String#endsWith\` over other equivalent methods of checking substrings", - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-string-starts-ends-with", - }, - "fixable": "code", - "messages": { - "preferEndsWith": "Use the 'String#endsWith' method instead.", - "preferStartsWith": "Use 'String#startsWith' method instead.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowSingleElementEquality": { - "description": "Whether to allow equality checks against the first or last element of a string.", - "enum": [ - "always", - "never", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-ts-expect-error": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce using \`@ts-expect-error\` over \`@ts-ignore\`", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/prefer-ts-expect-error", - }, - "fixable": "code", - "messages": { - "preferExpectErrorComment": "Use "@ts-expect-error" to ensure an error is actually being suppressed.", - }, - "schema": [], - "type": "problem", - }, - }, - "promise-function-async": { - "create": [Function], - "defaultOptions": [ - { - "allowAny": true, - "allowedPromiseNames": [], - "checkArrowFunctions": true, - "checkFunctionDeclarations": true, - "checkFunctionExpressions": true, - "checkMethodDeclarations": true, - }, - ], - "meta": { - "docs": { - "description": "Require any function or method that returns a Promise to be marked async", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/promise-function-async", - }, - "fixable": "code", - "messages": { - "missingAsync": "Functions that return promises must be async.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAny": { - "description": "Whether to consider \`any\` and \`unknown\` to be Promises.", - "type": "boolean", - }, - "allowedPromiseNames": { - "description": "Any extra names of classes or interfaces to be considered Promises.", - "items": { - "type": "string", - }, - "type": "array", - }, - "checkArrowFunctions": { - "type": "boolean", - }, - "checkFunctionDeclarations": { - "type": "boolean", - }, - "checkFunctionExpressions": { - "type": "boolean", - }, - "checkMethodDeclarations": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "quotes": { - "create": [Function], - "defaultOptions": [ - "double", - { - "allowTemplateLiterals": false, - "avoidEscape": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce the consistent use of either backticks, double, or single quotes", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/quotes", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "wrongQuotes": "Strings must use {{description}}.", - }, - "replacedBy": [ - "@stylistic/ts/quotes", - ], - "schema": [ - { - "enum": [ - "single", - "double", - "backtick", - ], - }, - { - "anyOf": [ - { - "enum": [ - "avoid-escape", - ], - }, - { - "additionalProperties": false, - "properties": { - "allowTemplateLiterals": { - "type": "boolean", - }, - "avoidEscape": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "layout", - }, - }, - "require-array-sort-compare": { - "create": [Function], - "defaultOptions": [ - { - "ignoreStringArrays": true, - }, - ], - "meta": { - "docs": { - "description": "Require \`Array#sort\` and \`Array#toSorted\` calls to always provide a \`compareFunction\`", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/require-array-sort-compare", - }, - "messages": { - "requireCompare": "Require 'compare' argument.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreStringArrays": { - "description": "Whether to ignore arrays in which all elements are strings.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "require-await": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow async functions which have no \`await\` expression", - "extendsBaseRule": true, - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/require-await", - }, - "messages": { - "missingAwait": "{{name}} has no 'await' expression.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "restrict-plus-operands": { - "create": [Function], - "defaultOptions": [ - { - "allowAny": true, - "allowBoolean": true, - "allowNullish": true, - "allowNumberAndString": true, - "allowRegExp": true, - "skipCompoundAssignments": false, - }, - ], - "meta": { - "docs": { - "description": "Require both operands of addition to be the same type and be \`bigint\`, \`number\`, or \`string\`", - "recommended": { - "recommended": true, - "strict": [ - { - "allowAny": false, - "allowBoolean": false, - "allowNullish": false, - "allowNumberAndString": false, - "allowRegExp": false, - }, - ], - }, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/restrict-plus-operands", - }, - "messages": { - "bigintAndNumber": "Numeric '+' operations must either be both bigints or both numbers. Got \`{{left}}\` + \`{{right}}\`.", - "invalid": "Invalid operand for a '+' operation. Operands must each be a number or {{stringLike}}. Got \`{{type}}\`.", - "mismatched": "Operands of '+' operations must be a number or {{stringLike}}. Got \`{{left}}\` + \`{{right}}\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAny": { - "description": "Whether to allow \`any\` typed values.", - "type": "boolean", - }, - "allowBoolean": { - "description": "Whether to allow \`boolean\` typed values.", - "type": "boolean", - }, - "allowNullish": { - "description": "Whether to allow potentially \`null\` or \`undefined\` typed values.", - "type": "boolean", - }, - "allowNumberAndString": { - "description": "Whether to allow \`bigint\`/\`number\` typed values and \`string\` typed values to be added together.", - "type": "boolean", - }, - "allowRegExp": { - "description": "Whether to allow \`regexp\` typed values.", - "type": "boolean", - }, - "skipCompoundAssignments": { - "description": "Whether to skip compound assignments such as \`+=\`.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "restrict-template-expressions": { - "create": [Function], - "defaultOptions": [ - { - "allowAny": true, - "allowBoolean": true, - "allowNullish": true, - "allowNumber": true, - "allowRegExp": true, - }, - ], - "meta": { - "docs": { - "description": "Enforce template literal expressions to be of \`string\` type", - "recommended": { - "recommended": true, - "strict": [ - { - "allowAny": false, - "allowBoolean": false, - "allowNever": false, - "allowNullish": false, - "allowNumber": false, - "allowRegExp": false, - }, - ], - }, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/restrict-template-expressions", - }, - "messages": { - "invalidType": "Invalid type "{{type}}" of template literal expression.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAny": { - "description": "Whether to allow \`any\` typed values in template expressions.", - "type": "boolean", - }, - "allowArray": { - "description": "Whether to allow \`array\` typed values in template expressions.", - "type": "boolean", - }, - "allowBoolean": { - "description": "Whether to allow \`boolean\` typed values in template expressions.", - "type": "boolean", - }, - "allowNever": { - "description": "Whether to allow \`never\` typed values in template expressions.", - "type": "boolean", - }, - "allowNullish": { - "description": "Whether to allow \`nullish\` typed values in template expressions.", - "type": "boolean", - }, - "allowNumber": { - "description": "Whether to allow \`number\` typed values in template expressions.", - "type": "boolean", - }, - "allowRegExp": { - "description": "Whether to allow \`regexp\` typed values in template expressions.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "return-await": { - "create": [Function], - "defaultOptions": [ - "in-try-catch", - ], - "meta": { - "docs": { - "description": "Enforce consistent returning of awaited values", - "extendsBaseRule": "no-return-await", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/return-await", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "disallowedPromiseAwait": "Returning an awaited promise is not allowed in this context.", - "nonPromiseAwait": "Returning an awaited value that is not a promise is not allowed.", - "requiredPromiseAwait": "Returning an awaited promise is required in this context.", - }, - "schema": [ - { - "enum": [ - "in-try-catch", - "always", - "never", - ], - "type": "string", - }, - ], - "type": "problem", - }, - }, - "semi": { - "create": [Function], - "defaultOptions": [ - "always", - { - "beforeStatementContinuationChars": "any", - "omitLastInOneLineBlock": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow semicolons instead of ASI", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/semi", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "extraSemi": "Extra semicolon.", - "missingSemi": "Missing semicolon.", - }, - "replacedBy": [ - "@stylistic/ts/semi", - ], - "schema": { - "anyOf": [ - { - "items": [ - { - "enum": [ - "never", - ], - }, - { - "additionalProperties": false, - "properties": { - "beforeStatementContinuationChars": { - "enum": [ - "always", - "any", - "never", - ], - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - { - "items": [ - { - "enum": [ - "always", - ], - }, - { - "additionalProperties": false, - "properties": { - "omitLastInOneLineBlock": { - "type": "boolean", - }, - "omitLastInOneLineClassBody": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - ], - }, - "type": "layout", - }, - }, - "sort-type-constituents": { - "create": [Function], - "defaultOptions": [ - { - "checkIntersections": true, - "checkUnions": true, - "groupOrder": [ - "named", - "keyword", - "operator", - "literal", - "function", - "import", - "conditional", - "object", - "tuple", - "intersection", - "union", - "nullish", - ], - }, - ], - "meta": { - "docs": { - "description": "Enforce constituents of a type union/intersection to be sorted alphabetically", - "url": "https://typescript-eslint.io/rules/sort-type-constituents", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "notSorted": "{{type}} type constituents must be sorted.", - "notSortedNamed": "{{type}} type {{name}} constituents must be sorted.", - "suggestFix": "Sort constituents of type (removes all comments).", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "checkIntersections": { - "description": "Whether to check intersection types.", - "type": "boolean", - }, - "checkUnions": { - "description": "Whether to check union types.", - "type": "boolean", - }, - "groupOrder": { - "description": "Ordering of the groups.", - "items": { - "enum": [ - "conditional", - "function", - "import", - "intersection", - "keyword", - "nullish", - "literal", - "named", - "object", - "operator", - "tuple", - "union", - ], - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "space-before-blocks": { - "create": [Function], - "defaultOptions": [ - "always", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing before blocks", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/space-before-blocks", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "missingSpace": "Missing space before opening brace.", - "unexpectedSpace": "Unexpected space before opening brace.", - }, - "replacedBy": [ - "@stylistic/ts/space-before-blocks", - ], - "schema": [ - { - "oneOf": [ - { - "enum": [ - "always", - "never", - ], - }, - { - "additionalProperties": false, - "properties": { - "classes": { - "enum": [ - "always", - "never", - "off", - ], - }, - "functions": { - "enum": [ - "always", - "never", - "off", - ], - }, - "keywords": { - "enum": [ - "always", - "never", - "off", - ], - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "layout", - }, - }, - "space-before-function-paren": { - "create": [Function], - "defaultOptions": [ - "always", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing before function parenthesis", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/space-before-function-paren", - }, - "fixable": "whitespace", - "messages": { - "missing": "Missing space before function parentheses.", - "unexpected": "Unexpected space before function parentheses.", - }, - "replacedBy": [ - "@stylistic/ts/space-before-function-paren", - ], - "schema": [ - { - "oneOf": [ - { - "enum": [ - "always", - "never", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "anonymous": { - "enum": [ - "always", - "never", - "ignore", - ], - "type": "string", - }, - "asyncArrow": { - "enum": [ - "always", - "never", - "ignore", - ], - "type": "string", - }, - "named": { - "enum": [ - "always", - "never", - "ignore", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "layout", - }, - }, - "space-infix-ops": { - "create": [Function], - "defaultOptions": [ - { - "int32Hint": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require spacing around infix operators", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/space-infix-ops", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "missingSpace": "Operator '{{operator}}' must be spaced.", - }, - "replacedBy": [ - "@stylistic/ts/space-infix-ops", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "int32Hint": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "strict-boolean-expressions": { - "create": [Function], - "defaultOptions": [ - { - "allowAny": false, - "allowNullableBoolean": false, - "allowNullableEnum": false, - "allowNullableNumber": false, - "allowNullableObject": true, - "allowNullableString": false, - "allowNumber": true, - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, - "allowString": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow certain types in boolean expressions", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/strict-boolean-expressions", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "conditionErrorAny": "Unexpected any value in conditional. An explicit comparison or type cast is required.", - "conditionErrorNullableBoolean": "Unexpected nullable boolean value in conditional. Please handle the nullish case explicitly.", - "conditionErrorNullableEnum": "Unexpected nullable enum value in conditional. Please handle the nullish/zero/NaN cases explicitly.", - "conditionErrorNullableNumber": "Unexpected nullable number value in conditional. Please handle the nullish/zero/NaN cases explicitly.", - "conditionErrorNullableObject": "Unexpected nullable object value in conditional. An explicit null check is required.", - "conditionErrorNullableString": "Unexpected nullable string value in conditional. Please handle the nullish/empty cases explicitly.", - "conditionErrorNullish": "Unexpected nullish value in conditional. The condition is always false.", - "conditionErrorNumber": "Unexpected number value in conditional. An explicit zero/NaN check is required.", - "conditionErrorObject": "Unexpected object value in conditional. The condition is always true.", - "conditionErrorOther": "Unexpected value in conditional. A boolean expression is required.", - "conditionErrorString": "Unexpected string value in conditional. An explicit empty string check is required.", - "conditionFixCastBoolean": "Explicitly cast value to a boolean (\`Boolean(value)\`)", - "conditionFixCompareEmptyString": "Change condition to check for empty string (\`value !== ""\`)", - "conditionFixCompareFalse": "Change condition to check if false (\`value === false\`)", - "conditionFixCompareNaN": "Change condition to check for NaN (\`!Number.isNaN(value)\`)", - "conditionFixCompareNullish": "Change condition to check for null/undefined (\`value != null\`)", - "conditionFixCompareStringLength": "Change condition to check string's length (\`value.length !== 0\`)", - "conditionFixCompareTrue": "Change condition to check if true (\`value === true\`)", - "conditionFixCompareZero": "Change condition to check for 0 (\`value !== 0\`)", - "conditionFixDefaultEmptyString": "Explicitly treat nullish value the same as an empty string (\`value ?? ""\`)", - "conditionFixDefaultFalse": "Explicitly treat nullish value the same as false (\`value ?? false\`)", - "conditionFixDefaultZero": "Explicitly treat nullish value the same as 0 (\`value ?? 0\`)", - "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAny": { - "type": "boolean", - }, - "allowNullableBoolean": { - "type": "boolean", - }, - "allowNullableEnum": { - "type": "boolean", - }, - "allowNullableNumber": { - "type": "boolean", - }, - "allowNullableObject": { - "type": "boolean", - }, - "allowNullableString": { - "type": "boolean", - }, - "allowNumber": { - "type": "boolean", - }, - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { - "type": "boolean", - }, - "allowString": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "switch-exhaustiveness-check": { - "create": [Function], - "defaultOptions": [ - { - "allowDefaultCaseForExhaustiveSwitch": true, - "requireDefaultForNonUnion": false, - }, - ], - "meta": { - "docs": { - "description": "Require switch-case statements to be exhaustive", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/switch-exhaustiveness-check", - }, - "hasSuggestions": true, - "messages": { - "addMissingCases": "Add branches for missing cases.", - "dangerousDefaultCase": "The switch statement is exhaustive, so the default case is unnecessary.", - "switchIsNotExhaustive": "Switch is not exhaustive. Cases not matched: {{missingBranches}}", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowDefaultCaseForExhaustiveSwitch": { - "description": "If 'true', allow 'default' cases on switch statements with exhaustive cases.", - "type": "boolean", - }, - "requireDefaultForNonUnion": { - "description": "If 'true', require a 'default' clause for switches on non-union types.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "triple-slash-reference": { - "create": [Function], - "defaultOptions": [ - { - "lib": "always", - "path": "never", - "types": "prefer-import", - }, - ], - "meta": { - "docs": { - "description": "Disallow certain triple slash directives in favor of ES6-style import declarations", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/triple-slash-reference", - }, - "messages": { - "tripleSlashReference": "Do not use a triple slash reference for {{module}}, use \`import\` style instead.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "lib": { - "enum": [ - "always", - "never", - ], - "type": "string", - }, - "path": { - "enum": [ - "always", - "never", - ], - "type": "string", - }, - "types": { - "enum": [ - "always", - "never", - "prefer-import", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "type-annotation-spacing": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require consistent spacing around type annotations", - "url": "https://typescript-eslint.io/rules/type-annotation-spacing", - }, - "fixable": "whitespace", - "messages": { - "expectedSpaceAfter": "Expected a space after the '{{type}}'.", - "expectedSpaceBefore": "Expected a space before the '{{type}}'.", - "unexpectedSpaceAfter": "Unexpected space after the '{{type}}'.", - "unexpectedSpaceBefore": "Unexpected space before the '{{type}}'.", - "unexpectedSpaceBetween": "Unexpected space between the '{{previousToken}}' and the '{{type}}'.", - }, - "replacedBy": [ - "@stylistic/ts/type-annotation-spacing", - ], - "schema": [ - { - "$defs": { - "spacingConfig": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - "overrides": { - "additionalProperties": false, - "properties": { - "arrow": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "colon": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "parameter": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "property": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "returnType": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "variable": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "typedef": { - "create": [Function], - "defaultOptions": [ - { - "arrayDestructuring": false, - "arrowParameter": false, - "memberVariableDeclaration": false, - "objectDestructuring": false, - "parameter": false, - "propertyDeclaration": false, - "variableDeclaration": false, - "variableDeclarationIgnoreFunction": false, - }, - ], - "meta": { - "docs": { - "description": "Require type annotations in certain places", - "url": "https://typescript-eslint.io/rules/typedef", - }, - "messages": { - "expectedTypedef": "Expected a type annotation.", - "expectedTypedefNamed": "Expected {{name}} to have a type annotation.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "arrayDestructuring": { - "type": "boolean", - }, - "arrowParameter": { - "type": "boolean", - }, - "memberVariableDeclaration": { - "type": "boolean", - }, - "objectDestructuring": { - "type": "boolean", - }, - "parameter": { - "type": "boolean", - }, - "propertyDeclaration": { - "type": "boolean", - }, - "variableDeclaration": { - "type": "boolean", - }, - "variableDeclarationIgnoreFunction": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "unbound-method": { - "create": [Function], - "defaultOptions": [ - { - "ignoreStatic": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce unbound methods are called with their expected scope", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/unbound-method", - }, - "messages": { - "unbound": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`.", - "unboundWithoutThisAnnotation": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`. -If your function does not access \`this\`, you can annotate it with \`this: void\`, or consider using an arrow function instead.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreStatic": { - "description": "Whether to skip checking whether \`static\` methods are correctly bound.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "unified-signatures": { - "create": [Function], - "defaultOptions": [ - { - "ignoreDifferentlyNamedParameters": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow two overloads that could be unified into one with a union or an optional/rest parameter", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/unified-signatures", - }, - "messages": { - "omittingRestParameter": "{{failureStringStart}} with a rest parameter.", - "omittingSingleParameter": "{{failureStringStart}} with an optional parameter.", - "singleParameterDifference": "{{failureStringStart}} taking \`{{type1}} | {{type2}}\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreDifferentlyNamedParameters": { - "description": "Whether two parameters with different names at the same index should be considered different even if their types are the same.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "use-unknown-in-catch-callback-variable": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce typing arguments in \`.catch()\` callbacks as \`unknown\`", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/use-unknown-in-catch-callback-variable", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "addUnknownRestTypeAnnotationSuggestion": "Add an explicit \`: [unknown]\` type annotation to the catch rest variable.", - "addUnknownTypeAnnotationSuggestion": "Add an explicit \`: unknown\` type annotation to the catch variable.", - "useUnknown": "Prefer the safe \`: unknown\` for a catch callback variable.", - "useUnknownArrayDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may not be iterable.", - "useUnknownObjectDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may be nullable, or may not have the expected shape.", - "useUnknownSpreadArgs": "Prefer the safe \`: unknown\` for a catch callback variable. The argument list may contain a handler that does not use \`unknown\` for the catch callback variable.", - "wrongRestTypeAnnotationSuggestion": "Change existing type annotation to \`: [unknown]\`.", - "wrongTypeAnnotationSuggestion": "Change existing type annotation to \`: unknown\`.", - }, - "schema": [], - "type": "suggestion", - }, - }, - }, - }, - }, - }, - { - "files": [ - "**/*.ts", - "**/*.tsx", - "**/*.mts", - "**/*.cts", - ], - "name": "jimmy.codes/typescript", - "rules": { - "constructor-super": "off", - "getter-return": "off", - "no-const-assign": "off", - "no-dupe-args": "off", - "no-dupe-class-members": "off", - "no-dupe-keys": "off", - "no-func-assign": "off", - "no-import-assign": "off", - "no-new-symbol": "off", - "no-obj-calls": "off", - "no-redeclare": "off", - "no-setter-return": "off", - "no-this-before-super": "off", - "no-undef": "off", - "no-unreachable": "off", - "no-unsafe-negation": "off", - "no-var": "error", - "prefer-const": "error", - "prefer-rest-params": "error", - "prefer-spread": "error", - }, - }, - { - "name": "jimmy.codes/typescript", - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": [ - "error", - { - "minimumDescriptionLength": 10, - }, - ], - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-array-delete": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-confusing-void-expression": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-dynamic-delete": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-extraneous-class": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-invalid-void-type": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-meaningless-void-operator": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-mixed-enums": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-non-null-assertion": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", - "@typescript-eslint/no-unnecessary-condition": "error", - "@typescript-eslint/no-unnecessary-type-arguments": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-useless-constructor": "error", - "@typescript-eslint/no-useless-template-literals": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/only-throw-error": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/prefer-includes": "error", - "@typescript-eslint/prefer-literal-enum-member": "error", - "@typescript-eslint/prefer-promise-reject-errors": "error", - "@typescript-eslint/prefer-reduce-type-parameter": "error", - "@typescript-eslint/prefer-return-this-type": "error", - "@typescript-eslint/prefer-ts-expect-error": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNullish": false, - "allowNumberAndString": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/restrict-template-expressions": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNever": false, - "allowNullish": false, - "allowNumber": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unbound-method": "error", - "@typescript-eslint/unified-signatures": "error", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", - "no-array-constructor": "off", - "no-implied-eval": "off", - "no-loss-of-precision": "off", - "no-throw-literal": "off", - "no-unused-vars": "off", - "no-useless-constructor": "off", - "prefer-promise-reject-errors": "off", - "require-await": "off", - }, - }, - { - "languageOptions": { - "parser": { - "meta": { - "name": "typescript-eslint/parser", - "version": "7.5.0", - }, - "parseForESLint": [Function], - }, - "sourceType": "module", - }, - "name": "jimmy.codes/typescript", - "plugins": { - "@typescript-eslint": { - "configs": { - "all": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/adjacent-overload-signatures": "error", - "@typescript-eslint/array-type": "error", - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": "error", - "@typescript-eslint/ban-tslint-comment": "error", - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/class-literal-property-style": "error", - "@typescript-eslint/class-methods-use-this": "error", - "@typescript-eslint/consistent-generic-constructors": "error", - "@typescript-eslint/consistent-indexed-object-style": "error", - "@typescript-eslint/consistent-return": "error", - "@typescript-eslint/consistent-type-assertions": "error", - "@typescript-eslint/consistent-type-definitions": "error", - "@typescript-eslint/consistent-type-exports": "error", - "@typescript-eslint/consistent-type-imports": "error", - "@typescript-eslint/default-param-last": "error", - "@typescript-eslint/dot-notation": "error", - "@typescript-eslint/explicit-function-return-type": "error", - "@typescript-eslint/explicit-member-accessibility": "error", - "@typescript-eslint/explicit-module-boundary-types": "error", - "@typescript-eslint/init-declarations": "error", - "@typescript-eslint/max-params": "error", - "@typescript-eslint/member-ordering": "error", - "@typescript-eslint/method-signature-style": "error", - "@typescript-eslint/naming-convention": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-array-delete": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-confusing-non-null-assertion": "error", - "@typescript-eslint/no-confusing-void-expression": "error", - "@typescript-eslint/no-dupe-class-members": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-dynamic-delete": "error", - "@typescript-eslint/no-empty-function": "error", - "@typescript-eslint/no-empty-interface": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-extraneous-class": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-import-type-side-effects": "error", - "@typescript-eslint/no-inferrable-types": "error", - "@typescript-eslint/no-invalid-this": "error", - "@typescript-eslint/no-invalid-void-type": "error", - "@typescript-eslint/no-loop-func": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-magic-numbers": "error", - "@typescript-eslint/no-meaningless-void-operator": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-mixed-enums": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-non-null-assertion": "error", - "@typescript-eslint/no-redeclare": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-require-imports": "error", - "@typescript-eslint/no-restricted-imports": "error", - "@typescript-eslint/no-shadow": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", - "@typescript-eslint/no-unnecessary-condition": "error", - "@typescript-eslint/no-unnecessary-qualifier": "error", - "@typescript-eslint/no-unnecessary-type-arguments": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unsafe-unary-minus": "error", - "@typescript-eslint/no-unused-expressions": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-use-before-define": "error", - "@typescript-eslint/no-useless-constructor": "error", - "@typescript-eslint/no-useless-empty-export": "error", - "@typescript-eslint/no-useless-template-literals": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/non-nullable-type-assertion-style": "error", - "@typescript-eslint/only-throw-error": "error", - "@typescript-eslint/parameter-properties": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/prefer-destructuring": "error", - "@typescript-eslint/prefer-enum-initializers": "error", - "@typescript-eslint/prefer-find": "error", - "@typescript-eslint/prefer-for-of": "error", - "@typescript-eslint/prefer-function-type": "error", - "@typescript-eslint/prefer-includes": "error", - "@typescript-eslint/prefer-literal-enum-member": "error", - "@typescript-eslint/prefer-namespace-keyword": "error", - "@typescript-eslint/prefer-nullish-coalescing": "error", - "@typescript-eslint/prefer-optional-chain": "error", - "@typescript-eslint/prefer-promise-reject-errors": "error", - "@typescript-eslint/prefer-readonly": "error", - "@typescript-eslint/prefer-readonly-parameter-types": "error", - "@typescript-eslint/prefer-reduce-type-parameter": "error", - "@typescript-eslint/prefer-regexp-exec": "error", - "@typescript-eslint/prefer-return-this-type": "error", - "@typescript-eslint/prefer-string-starts-ends-with": "error", - "@typescript-eslint/prefer-ts-expect-error": "error", - "@typescript-eslint/promise-function-async": "error", - "@typescript-eslint/require-array-sort-compare": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": "error", - "@typescript-eslint/restrict-template-expressions": "error", - "@typescript-eslint/return-await": "error", - "@typescript-eslint/sort-type-constituents": "error", - "@typescript-eslint/strict-boolean-expressions": "error", - "@typescript-eslint/switch-exhaustiveness-check": "error", - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/typedef": "error", - "@typescript-eslint/unbound-method": "error", - "@typescript-eslint/unified-signatures": "error", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", - "class-methods-use-this": "off", - "consistent-return": "off", - "default-param-last": "off", - "dot-notation": "off", - "init-declarations": "off", - "max-params": "off", - "no-array-constructor": "off", - "no-dupe-class-members": "off", - "no-empty-function": "off", - "no-implied-eval": "off", - "no-invalid-this": "off", - "no-loop-func": "off", - "no-loss-of-precision": "off", - "no-magic-numbers": "off", - "no-redeclare": "off", - "no-restricted-imports": "off", - "no-return-await": "off", - "no-shadow": "off", - "no-throw-literal": "off", - "no-unused-expressions": "off", - "no-unused-vars": "off", - "no-use-before-define": "off", - "no-useless-constructor": "off", - "prefer-destructuring": "off", - "prefer-promise-reject-errors": "off", - "require-await": "off", - }, - }, - "base": { - "parser": "@typescript-eslint/parser", - "parserOptions": { - "sourceType": "module", - }, - "plugins": [ - "@typescript-eslint", - ], - }, - "disable-type-checked": { - "parserOptions": { - "program": null, - "project": false, - }, - "rules": { - "@typescript-eslint/await-thenable": "off", - "@typescript-eslint/consistent-return": "off", - "@typescript-eslint/consistent-type-exports": "off", - "@typescript-eslint/dot-notation": "off", - "@typescript-eslint/naming-convention": "off", - "@typescript-eslint/no-array-delete": "off", - "@typescript-eslint/no-base-to-string": "off", - "@typescript-eslint/no-confusing-void-expression": "off", - "@typescript-eslint/no-duplicate-type-constituents": "off", - "@typescript-eslint/no-floating-promises": "off", - "@typescript-eslint/no-for-in-array": "off", - "@typescript-eslint/no-implied-eval": "off", - "@typescript-eslint/no-meaningless-void-operator": "off", - "@typescript-eslint/no-misused-promises": "off", - "@typescript-eslint/no-mixed-enums": "off", - "@typescript-eslint/no-redundant-type-constituents": "off", - "@typescript-eslint/no-throw-literal": "off", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off", - "@typescript-eslint/no-unnecessary-condition": "off", - "@typescript-eslint/no-unnecessary-qualifier": "off", - "@typescript-eslint/no-unnecessary-type-arguments": "off", - "@typescript-eslint/no-unnecessary-type-assertion": "off", - "@typescript-eslint/no-unsafe-argument": "off", - "@typescript-eslint/no-unsafe-assignment": "off", - "@typescript-eslint/no-unsafe-call": "off", - "@typescript-eslint/no-unsafe-enum-comparison": "off", - "@typescript-eslint/no-unsafe-member-access": "off", - "@typescript-eslint/no-unsafe-return": "off", - "@typescript-eslint/no-unsafe-unary-minus": "off", - "@typescript-eslint/no-useless-template-literals": "off", - "@typescript-eslint/non-nullable-type-assertion-style": "off", - "@typescript-eslint/only-throw-error": "off", - "@typescript-eslint/prefer-destructuring": "off", - "@typescript-eslint/prefer-find": "off", - "@typescript-eslint/prefer-includes": "off", - "@typescript-eslint/prefer-nullish-coalescing": "off", - "@typescript-eslint/prefer-optional-chain": "off", - "@typescript-eslint/prefer-promise-reject-errors": "off", - "@typescript-eslint/prefer-readonly": "off", - "@typescript-eslint/prefer-readonly-parameter-types": "off", - "@typescript-eslint/prefer-reduce-type-parameter": "off", - "@typescript-eslint/prefer-regexp-exec": "off", - "@typescript-eslint/prefer-return-this-type": "off", - "@typescript-eslint/prefer-string-starts-ends-with": "off", - "@typescript-eslint/promise-function-async": "off", - "@typescript-eslint/require-array-sort-compare": "off", - "@typescript-eslint/require-await": "off", - "@typescript-eslint/restrict-plus-operands": "off", - "@typescript-eslint/restrict-template-expressions": "off", - "@typescript-eslint/return-await": "off", - "@typescript-eslint/strict-boolean-expressions": "off", - "@typescript-eslint/switch-exhaustiveness-check": "off", - "@typescript-eslint/unbound-method": "off", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "off", - }, - }, - "eslint-recommended": { - "overrides": [ - { - "files": [ - "*.ts", - "*.tsx", - "*.mts", - "*.cts", - ], - "rules": { - "constructor-super": "off", - "getter-return": "off", - "no-const-assign": "off", - "no-dupe-args": "off", - "no-dupe-class-members": "off", - "no-dupe-keys": "off", - "no-func-assign": "off", - "no-import-assign": "off", - "no-new-symbol": "off", - "no-obj-calls": "off", - "no-redeclare": "off", - "no-setter-return": "off", - "no-this-before-super": "off", - "no-undef": "off", - "no-unreachable": "off", - "no-unsafe-negation": "off", - "no-var": "error", - "prefer-const": "error", - "prefer-rest-params": "error", - "prefer-spread": "error", - }, - }, - ], - }, - "recommended": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/ban-ts-comment": "error", - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/triple-slash-reference": "error", - "no-array-constructor": "off", - "no-loss-of-precision": "off", - "no-unused-vars": "off", - }, - }, - "recommended-requiring-type-checking": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": "error", - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": "error", - "@typescript-eslint/restrict-template-expressions": "error", - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unbound-method": "error", - "no-array-constructor": "off", - "no-implied-eval": "off", - "no-loss-of-precision": "off", - "no-unused-vars": "off", - "require-await": "off", - }, - }, - "recommended-type-checked": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": "error", - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": "error", - "@typescript-eslint/restrict-template-expressions": "error", - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unbound-method": "error", - "no-array-constructor": "off", - "no-implied-eval": "off", - "no-loss-of-precision": "off", - "no-unused-vars": "off", - "require-await": "off", - }, - }, - "recommended-type-checked-only": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": "error", - "@typescript-eslint/restrict-template-expressions": "error", - "@typescript-eslint/unbound-method": "error", - "no-implied-eval": "off", - "require-await": "off", - }, - }, - "strict": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/ban-ts-comment": [ - "error", - { - "minimumDescriptionLength": 10, - }, - ], - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-dynamic-delete": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-extraneous-class": "error", - "@typescript-eslint/no-invalid-void-type": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-non-null-assertion": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-useless-constructor": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/prefer-literal-enum-member": "error", - "@typescript-eslint/prefer-ts-expect-error": "error", - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unified-signatures": "error", - "no-array-constructor": "off", - "no-loss-of-precision": "off", - "no-unused-vars": "off", - "no-useless-constructor": "off", - }, - }, - "strict-type-checked": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/ban-ts-comment": [ - "error", - { - "minimumDescriptionLength": 10, - }, - ], - "@typescript-eslint/ban-types": "error", - "@typescript-eslint/no-array-constructor": "error", - "@typescript-eslint/no-array-delete": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-confusing-void-expression": "error", - "@typescript-eslint/no-duplicate-enum-values": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-dynamic-delete": "error", - "@typescript-eslint/no-explicit-any": "error", - "@typescript-eslint/no-extra-non-null-assertion": "error", - "@typescript-eslint/no-extraneous-class": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-invalid-void-type": "error", - "@typescript-eslint/no-loss-of-precision": "error", - "@typescript-eslint/no-meaningless-void-operator": "error", - "@typescript-eslint/no-misused-new": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-mixed-enums": "error", - "@typescript-eslint/no-namespace": "error", - "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", - "@typescript-eslint/no-non-null-asserted-optional-chain": "error", - "@typescript-eslint/no-non-null-assertion": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-this-alias": "error", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", - "@typescript-eslint/no-unnecessary-condition": "error", - "@typescript-eslint/no-unnecessary-type-arguments": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unnecessary-type-constraint": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-declaration-merging": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-unused-vars": "error", - "@typescript-eslint/no-useless-constructor": "error", - "@typescript-eslint/no-useless-template-literals": "error", - "@typescript-eslint/no-var-requires": "error", - "@typescript-eslint/only-throw-error": "error", - "@typescript-eslint/prefer-as-const": "error", - "@typescript-eslint/prefer-includes": "error", - "@typescript-eslint/prefer-literal-enum-member": "error", - "@typescript-eslint/prefer-promise-reject-errors": "error", - "@typescript-eslint/prefer-reduce-type-parameter": "error", - "@typescript-eslint/prefer-return-this-type": "error", - "@typescript-eslint/prefer-ts-expect-error": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNullish": false, - "allowNumberAndString": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/restrict-template-expressions": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNever": false, - "allowNullish": false, - "allowNumber": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/triple-slash-reference": "error", - "@typescript-eslint/unbound-method": "error", - "@typescript-eslint/unified-signatures": "error", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", - "no-array-constructor": "off", - "no-implied-eval": "off", - "no-loss-of-precision": "off", - "no-throw-literal": "off", - "no-unused-vars": "off", - "no-useless-constructor": "off", - "prefer-promise-reject-errors": "off", - "require-await": "off", - }, - }, - "strict-type-checked-only": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/await-thenable": "error", - "@typescript-eslint/no-array-delete": "error", - "@typescript-eslint/no-base-to-string": "error", - "@typescript-eslint/no-confusing-void-expression": "error", - "@typescript-eslint/no-duplicate-type-constituents": "error", - "@typescript-eslint/no-floating-promises": "error", - "@typescript-eslint/no-for-in-array": "error", - "@typescript-eslint/no-implied-eval": "error", - "@typescript-eslint/no-meaningless-void-operator": "error", - "@typescript-eslint/no-misused-promises": "error", - "@typescript-eslint/no-mixed-enums": "error", - "@typescript-eslint/no-redundant-type-constituents": "error", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", - "@typescript-eslint/no-unnecessary-condition": "error", - "@typescript-eslint/no-unnecessary-type-arguments": "error", - "@typescript-eslint/no-unnecessary-type-assertion": "error", - "@typescript-eslint/no-unsafe-argument": "error", - "@typescript-eslint/no-unsafe-assignment": "error", - "@typescript-eslint/no-unsafe-call": "error", - "@typescript-eslint/no-unsafe-enum-comparison": "error", - "@typescript-eslint/no-unsafe-member-access": "error", - "@typescript-eslint/no-unsafe-return": "error", - "@typescript-eslint/no-useless-template-literals": "error", - "@typescript-eslint/only-throw-error": "error", - "@typescript-eslint/prefer-includes": "error", - "@typescript-eslint/prefer-promise-reject-errors": "error", - "@typescript-eslint/prefer-reduce-type-parameter": "error", - "@typescript-eslint/prefer-return-this-type": "error", - "@typescript-eslint/require-await": "error", - "@typescript-eslint/restrict-plus-operands": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNullish": false, - "allowNumberAndString": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/restrict-template-expressions": [ - "error", - { - "allowAny": false, - "allowBoolean": false, - "allowNever": false, - "allowNullish": false, - "allowNumber": false, - "allowRegExp": false, - }, - ], - "@typescript-eslint/unbound-method": "error", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", - "no-implied-eval": "off", - "no-throw-literal": "off", - "prefer-promise-reject-errors": "off", - "require-await": "off", - }, - }, - "stylistic": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/adjacent-overload-signatures": "error", - "@typescript-eslint/array-type": "error", - "@typescript-eslint/ban-tslint-comment": "error", - "@typescript-eslint/class-literal-property-style": "error", - "@typescript-eslint/consistent-generic-constructors": "error", - "@typescript-eslint/consistent-indexed-object-style": "error", - "@typescript-eslint/consistent-type-assertions": "error", - "@typescript-eslint/consistent-type-definitions": "error", - "@typescript-eslint/no-confusing-non-null-assertion": "error", - "@typescript-eslint/no-empty-function": "error", - "@typescript-eslint/no-empty-interface": "error", - "@typescript-eslint/no-inferrable-types": "error", - "@typescript-eslint/prefer-for-of": "error", - "@typescript-eslint/prefer-function-type": "error", - "@typescript-eslint/prefer-namespace-keyword": "error", - "no-empty-function": "off", - }, - }, - "stylistic-type-checked": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/adjacent-overload-signatures": "error", - "@typescript-eslint/array-type": "error", - "@typescript-eslint/ban-tslint-comment": "error", - "@typescript-eslint/class-literal-property-style": "error", - "@typescript-eslint/consistent-generic-constructors": "error", - "@typescript-eslint/consistent-indexed-object-style": "error", - "@typescript-eslint/consistent-type-assertions": "error", - "@typescript-eslint/consistent-type-definitions": "error", - "@typescript-eslint/dot-notation": "error", - "@typescript-eslint/no-confusing-non-null-assertion": "error", - "@typescript-eslint/no-empty-function": "error", - "@typescript-eslint/no-empty-interface": "error", - "@typescript-eslint/no-inferrable-types": "error", - "@typescript-eslint/non-nullable-type-assertion-style": "error", - "@typescript-eslint/prefer-for-of": "error", - "@typescript-eslint/prefer-function-type": "error", - "@typescript-eslint/prefer-namespace-keyword": "error", - "@typescript-eslint/prefer-nullish-coalescing": "error", - "@typescript-eslint/prefer-optional-chain": "error", - "@typescript-eslint/prefer-string-starts-ends-with": "error", - "dot-notation": "off", - "no-empty-function": "off", - }, - }, - "stylistic-type-checked-only": { - "extends": [ - "./configs/base", - "./configs/eslint-recommended", - ], - "rules": { - "@typescript-eslint/dot-notation": "error", - "@typescript-eslint/non-nullable-type-assertion-style": "error", - "@typescript-eslint/prefer-nullish-coalescing": "error", - "@typescript-eslint/prefer-optional-chain": "error", - "@typescript-eslint/prefer-string-starts-ends-with": "error", - "dot-notation": "off", - }, - }, - }, - "meta": { - "name": "@typescript-eslint/eslint-plugin", - "version": "7.5.0", - }, - "rules": { - "adjacent-overload-signatures": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Require that function overload signatures be consecutive", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/adjacent-overload-signatures", - }, - "messages": { - "adjacentSignature": "All {{name}} signatures should be adjacent.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "array-type": { - "create": [Function], - "defaultOptions": [ - { - "default": "array", - }, - ], - "meta": { - "docs": { - "description": "Require consistently using either \`T[]\` or \`Array\` for arrays", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/array-type", - }, - "fixable": "code", - "messages": { - "errorStringArray": "Array type using '{{className}}<{{type}}>' is forbidden. Use '{{readonlyPrefix}}{{type}}[]' instead.", - "errorStringArraySimple": "Array type using '{{className}}<{{type}}>' is forbidden for simple types. Use '{{readonlyPrefix}}{{type}}[]' instead.", - "errorStringGeneric": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden. Use '{{className}}<{{type}}>' instead.", - "errorStringGenericSimple": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden for non-simple types. Use '{{className}}<{{type}}>' instead.", - }, - "schema": [ - { - "$defs": { - "arrayOption": { - "enum": [ - "array", - "generic", - "array-simple", - ], - "type": "string", - }, - }, - "additionalProperties": false, - "properties": { - "default": { - "$ref": "#/items/0/$defs/arrayOption", - "description": "The array type expected for mutable cases.", - }, - "readonly": { - "$ref": "#/items/0/$defs/arrayOption", - "description": "The array type expected for readonly cases. If omitted, the value for \`default\` will be used.", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "await-thenable": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow awaiting a value that is not a Thenable", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/await-thenable", - }, - "hasSuggestions": true, - "messages": { - "await": "Unexpected \`await\` of a non-Promise (non-"Thenable") value.", - "removeAwait": "Remove unnecessary \`await\`.", - }, - "schema": [], - "type": "problem", - }, - }, - "ban-ts-comment": { - "create": [Function], - "defaultOptions": [ - { - "minimumDescriptionLength": 3, - "ts-check": false, - "ts-expect-error": "allow-with-description", - "ts-ignore": true, - "ts-nocheck": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow \`@ts-\` comments or require descriptions after directives", - "recommended": { - "recommended": true, - "strict": [ - { - "minimumDescriptionLength": 10, - }, - ], - }, - "url": "https://typescript-eslint.io/rules/ban-ts-comment", - }, - "hasSuggestions": true, - "messages": { - "replaceTsIgnoreWithTsExpectError": "Replace "@ts-ignore" with "@ts-expect-error".", - "tsDirectiveComment": "Do not use "@ts-{{directive}}" because it alters compilation errors.", - "tsDirectiveCommentDescriptionNotMatchPattern": "The description for the "@ts-{{directive}}" directive must match the {{format}} format.", - "tsDirectiveCommentRequiresDescription": "Include a description after the "@ts-{{directive}}" directive to explain why the @ts-{{directive}} is necessary. The description must be {{minimumDescriptionLength}} characters or longer.", - "tsIgnoreInsteadOfExpectError": "Use "@ts-expect-error" instead of "@ts-ignore", as "@ts-ignore" will do nothing if the following line is error-free.", - }, - "schema": [ - { - "$defs": { - "directiveConfigSchema": { - "oneOf": [ - { - "default": true, - "type": "boolean", - }, - { - "enum": [ - "allow-with-description", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "descriptionFormat": { - "type": "string", - }, - }, - "type": "object", - }, - ], - }, - }, - "additionalProperties": false, - "properties": { - "minimumDescriptionLength": { - "default": 3, - "type": "number", - }, - "ts-check": { - "$ref": "#/items/0/$defs/directiveConfigSchema", - }, - "ts-expect-error": { - "$ref": "#/items/0/$defs/directiveConfigSchema", - }, - "ts-ignore": { - "$ref": "#/items/0/$defs/directiveConfigSchema", - }, - "ts-nocheck": { - "$ref": "#/items/0/$defs/directiveConfigSchema", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "ban-tslint-comment": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow \`// tslint:\` comments", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/ban-tslint-comment", - }, - "fixable": "code", - "messages": { - "commentDetected": "tslint comment detected: "{{ text }}"", - }, - "schema": [], - "type": "suggestion", - }, - }, - "ban-types": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "docs": { - "description": "Disallow certain types", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/ban-types", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "bannedTypeMessage": "Don't use \`{{name}}\` as a type.{{customMessage}}", - "bannedTypeReplacement": "Replace \`{{name}}\` with \`{{replacement}}\`.", - }, - "schema": [ - { - "$defs": { - "banConfig": { - "oneOf": [ - { - "description": "Bans the type with the default message", - "type": "null", - }, - { - "description": "Un-bans the type (useful when paired with \`extendDefaults\`)", - "enum": [ - false, - ], - "type": "boolean", - }, - { - "description": "Bans the type with the default message", - "enum": [ - true, - ], - "type": "boolean", - }, - { - "description": "Bans the type with a custom message", - "type": "string", - }, - { - "additionalProperties": false, - "description": "Bans a type", - "properties": { - "fixWith": { - "description": "Type to autofix replace with. Note that autofixers can be applied automatically - so you need to be careful with this option.", - "type": "string", - }, - "message": { - "description": "Custom error message", - "type": "string", - }, - "suggest": { - "additionalItems": false, - "description": "Types to suggest replacing with.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - }, - }, - "additionalProperties": false, - "properties": { - "extendDefaults": { - "type": "boolean", - }, - "types": { - "additionalProperties": { - "$ref": "#/items/0/$defs/banConfig", - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "block-spacing": { - "create": [Function], - "defaultOptions": [ - "always", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow or enforce spaces inside of blocks after opening block and before closing block", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/block-spacing", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "extra": "Unexpected space(s) {{location}} '{{token}}'.", - "missing": "Requires a space {{location}} '{{token}}'.", - }, - "replacedBy": [ - "@stylistic/ts/block-spacing", - ], - "schema": [ - { - "enum": [ - "always", - "never", - ], - }, - ], - "type": "layout", - }, - }, - "brace-style": { - "create": [Function], - "defaultOptions": [ - "1tbs", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent brace style for blocks", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/brace-style", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "blockSameLine": "Statement inside of curly braces should be on next line.", - "nextLineClose": "Closing curly brace does not appear on the same line as the subsequent block.", - "nextLineOpen": "Opening curly brace does not appear on the same line as controlling statement.", - "sameLineClose": "Closing curly brace appears on the same line as the subsequent block.", - "sameLineOpen": "Opening curly brace appears on the same line as controlling statement.", - "singleLineClose": "Closing curly brace should be on the same line as opening curly brace or on the line after the previous block.", - }, - "replacedBy": [ - "@stylistic/ts/brace-style", - ], - "schema": [ - { - "enum": [ - "1tbs", - "stroustrup", - "allman", - ], - }, - { - "additionalProperties": false, - "properties": { - "allowSingleLine": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "class-literal-property-style": { - "create": [Function], - "defaultOptions": [ - "fields", - ], - "meta": { - "docs": { - "description": "Enforce that literals on classes are exposed in a consistent style", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/class-literal-property-style", - }, - "hasSuggestions": true, - "messages": { - "preferFieldStyle": "Literals should be exposed using readonly fields.", - "preferFieldStyleSuggestion": "Replace the literals with readonly fields.", - "preferGetterStyle": "Literals should be exposed using getters.", - "preferGetterStyleSuggestion": "Replace the literals with getters.", - }, - "schema": [ - { - "enum": [ - "fields", - "getters", - ], - "type": "string", - }, - ], - "type": "problem", - }, - }, - "class-methods-use-this": { - "create": [Function], - "defaultOptions": [ - { - "enforceForClassFields": true, - "exceptMethods": [], - "ignoreClassesThatImplementAnInterface": false, - "ignoreOverrideMethods": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce that class methods utilize \`this\`", - "extendsBaseRule": true, - "requiresTypeChecking": false, - "url": "https://typescript-eslint.io/rules/class-methods-use-this", - }, - "messages": { - "missingThis": "Expected 'this' to be used by class {{name}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "enforceForClassFields": { - "default": true, - "description": "Enforces that functions used as instance field initializers utilize \`this\`", - "type": "boolean", - }, - "exceptMethods": { - "description": "Allows specified method names to be ignored with this rule", - "items": { - "type": "string", - }, - "type": "array", - }, - "ignoreClassesThatImplementAnInterface": { - "description": "Ignore classes that specifically implement some interface", - "oneOf": [ - { - "description": "Ignore all classes that implement an interface", - "type": "boolean", - }, - { - "description": "Ignore only the public fields of classes that implement an interface", - "enum": [ - "public-fields", - ], - "type": "string", - }, - ], - }, - "ignoreOverrideMethods": { - "description": "Ignore members marked with the \`override\` modifier", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "comma-dangle": { - "create": [Function], - "defaultOptions": [ - "never", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow trailing commas", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/comma-dangle", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "missing": "Missing trailing comma.", - "unexpected": "Unexpected trailing comma.", - }, - "replacedBy": [ - "@stylistic/ts/comma-dangle", - ], - "schema": { - "$defs": { - "value": { - "enum": [ - "always-multiline", - "always", - "never", - "only-multiline", - ], - "type": "string", - }, - "valueWithIgnore": { - "enum": [ - "always-multiline", - "always", - "never", - "only-multiline", - "ignore", - ], - "type": "string", - }, - }, - "additionalItems": false, - "items": [ - { - "oneOf": [ - { - "$ref": "#/$defs/value", - }, - { - "additionalProperties": false, - "properties": { - "arrays": { - "$ref": "#/$defs/valueWithIgnore", - }, - "enums": { - "$ref": "#/$defs/valueWithIgnore", - }, - "exports": { - "$ref": "#/$defs/valueWithIgnore", - }, - "functions": { - "$ref": "#/$defs/valueWithIgnore", - }, - "generics": { - "$ref": "#/$defs/valueWithIgnore", - }, - "imports": { - "$ref": "#/$defs/valueWithIgnore", - }, - "objects": { - "$ref": "#/$defs/valueWithIgnore", - }, - "tuples": { - "$ref": "#/$defs/valueWithIgnore", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "array", - }, - "type": "layout", - }, - }, - "comma-spacing": { - "create": [Function], - "defaultOptions": [ - { - "after": true, - "before": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing before and after commas", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/comma-spacing", - }, - "fixable": "whitespace", - "messages": { - "missing": "A space is required {{loc}} ','.", - "unexpected": "There should be no space {{loc}} ','.", - }, - "replacedBy": [ - "@stylistic/ts/comma-spacing", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "after": { - "default": true, - "type": "boolean", - }, - "before": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "consistent-generic-constructors": { - "create": [Function], - "defaultOptions": [ - "constructor", - ], - "meta": { - "docs": { - "description": "Enforce specifying generic type arguments on type annotation or constructor name of a constructor call", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/consistent-generic-constructors", - }, - "fixable": "code", - "messages": { - "preferConstructor": "The generic type arguments should be specified as part of the constructor type arguments.", - "preferTypeAnnotation": "The generic type arguments should be specified as part of the type annotation.", - }, - "schema": [ - { - "enum": [ - "type-annotation", - "constructor", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "consistent-indexed-object-style": { - "create": [Function], - "defaultOptions": [ - "record", - ], - "meta": { - "docs": { - "description": "Require or disallow the \`Record\` type", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/consistent-indexed-object-style", - }, - "fixable": "code", - "messages": { - "preferIndexSignature": "An index signature is preferred over a record.", - "preferRecord": "A record is preferred over an index signature.", - }, - "schema": [ - { - "enum": [ - "record", - "index-signature", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "consistent-return": { - "create": [Function], - "defaultOptions": [ - { - "treatUndefinedAsUnspecified": false, - }, - ], - "meta": { - "docs": { - "description": "Require \`return\` statements to either always or never specify values", - "extendsBaseRule": true, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/consistent-return", - }, - "hasSuggestions": undefined, - "messages": { - "missingReturn": "Expected to return a value at the end of {{name}}.", - "missingReturnValue": "{{name}} expected a return value.", - "unexpectedReturnValue": "{{name}} expected no return value.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "treatUndefinedAsUnspecified": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "consistent-type-assertions": { - "create": [Function], - "defaultOptions": [ - { - "assertionStyle": "as", - "objectLiteralTypeAssertions": "allow", - }, - ], - "meta": { - "docs": { - "description": "Enforce consistent usage of type assertions", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/consistent-type-assertions", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "angle-bracket": "Use '<{{cast}}>' instead of 'as {{cast}}'.", - "as": "Use 'as {{cast}}' instead of '<{{cast}}>'.", - "never": "Do not use any type assertions.", - "replaceObjectTypeAssertionWithAnnotation": "Use const x: {{cast}} = { ... } instead.", - "replaceObjectTypeAssertionWithSatisfies": "Use const x = { ... } satisfies {{cast}} instead.", - "unexpectedObjectTypeAssertion": "Always prefer const x: T = { ... }.", - }, - "schema": [ - { - "oneOf": [ - { - "additionalProperties": false, - "properties": { - "assertionStyle": { - "enum": [ - "never", - ], - "type": "string", - }, - }, - "required": [ - "assertionStyle", - ], - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "assertionStyle": { - "enum": [ - "as", - "angle-bracket", - ], - "type": "string", - }, - "objectLiteralTypeAssertions": { - "enum": [ - "allow", - "allow-as-parameter", - "never", - ], - "type": "string", - }, - }, - "required": [ - "assertionStyle", - ], - "type": "object", - }, - ], - }, - ], - "type": "suggestion", - }, - }, - "consistent-type-definitions": { - "create": [Function], - "defaultOptions": [ - "interface", - ], - "meta": { - "docs": { - "description": "Enforce type definitions to consistently use either \`interface\` or \`type\`", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/consistent-type-definitions", - }, - "fixable": "code", - "messages": { - "interfaceOverType": "Use an \`interface\` instead of a \`type\`.", - "typeOverInterface": "Use a \`type\` instead of an \`interface\`.", - }, - "schema": [ - { - "enum": [ - "interface", - "type", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "consistent-type-exports": { - "create": [Function], - "defaultOptions": [ - { - "fixMixedExportsWithInlineTypeSpecifier": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce consistent usage of type exports", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/consistent-type-exports", - }, - "fixable": "code", - "messages": { - "multipleExportsAreTypes": "Type exports {{exportNames}} are not values and should be exported using \`export type\`.", - "singleExportIsType": "Type export {{exportNames}} is not a value and should be exported using \`export type\`.", - "typeOverValue": "All exports in the declaration are only used as types. Use \`export type\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "fixMixedExportsWithInlineTypeSpecifier": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "consistent-type-imports": { - "create": [Function], - "defaultOptions": [ - { - "disallowTypeAnnotations": true, - "fixStyle": "separate-type-imports", - "prefer": "type-imports", - }, - ], - "meta": { - "docs": { - "description": "Enforce consistent usage of type imports", - "url": "https://typescript-eslint.io/rules/consistent-type-imports", - }, - "fixable": "code", - "messages": { - "avoidImportType": "Use an \`import\` instead of an \`import type\`.", - "noImportTypeAnnotations": "\`import()\` type annotations are forbidden.", - "someImportsAreOnlyTypes": "Imports {{typeImports}} are only used as type.", - "typeOverValue": "All imports in the declaration are only used as types. Use \`import type\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "disallowTypeAnnotations": { - "type": "boolean", - }, - "fixStyle": { - "enum": [ - "separate-type-imports", - "inline-type-imports", - ], - "type": "string", - }, - "prefer": { - "enum": [ - "type-imports", - "no-type-imports", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "default-param-last": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce default parameters to be last", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/default-param-last", - }, - "messages": { - "shouldBeLast": "Default parameters should be last.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "dot-notation": { - "create": [Function], - "defaultOptions": [ - { - "allowIndexSignaturePropertyAccess": false, - "allowKeywords": true, - "allowPattern": "", - "allowPrivateClassPropertyAccess": false, - "allowProtectedClassPropertyAccess": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce dot notation whenever possible", - "extendsBaseRule": true, - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/dot-notation", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "useBrackets": ".{{key}} is a syntax error.", - "useDot": "[{{key}}] is better written in dot notation.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowIndexSignaturePropertyAccess": { - "default": false, - "type": "boolean", - }, - "allowKeywords": { - "default": true, - "type": "boolean", - }, - "allowPattern": { - "default": "", - "type": "string", - }, - "allowPrivateClassPropertyAccess": { - "default": false, - "type": "boolean", - }, - "allowProtectedClassPropertyAccess": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "explicit-function-return-type": { - "create": [Function], - "defaultOptions": [ - { - "allowConciseArrowFunctionExpressionsStartingWithVoid": false, - "allowDirectConstAssertionInArrowFunctions": true, - "allowExpressions": false, - "allowFunctionsWithoutTypeParameters": false, - "allowHigherOrderFunctions": true, - "allowIIFEs": false, - "allowTypedFunctionExpressions": true, - "allowedNames": [], - }, - ], - "meta": { - "docs": { - "description": "Require explicit return types on functions and class methods", - "url": "https://typescript-eslint.io/rules/explicit-function-return-type", - }, - "messages": { - "missingReturnType": "Missing return type on function.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowConciseArrowFunctionExpressionsStartingWithVoid": { - "description": "Whether to allow arrow functions that start with the \`void\` keyword.", - "type": "boolean", - }, - "allowDirectConstAssertionInArrowFunctions": { - "description": "Whether to ignore arrow functions immediately returning a \`as const\` value.", - "type": "boolean", - }, - "allowExpressions": { - "description": "Whether to ignore function expressions (functions which are not part of a declaration).", - "type": "boolean", - }, - "allowFunctionsWithoutTypeParameters": { - "description": "Whether to ignore functions that don't have generic type parameters.", - "type": "boolean", - }, - "allowHigherOrderFunctions": { - "description": "Whether to ignore functions immediately returning another function expression.", - "type": "boolean", - }, - "allowIIFEs": { - "description": "Whether to ignore immediately invoked function expressions (IIFEs).", - "type": "boolean", - }, - "allowTypedFunctionExpressions": { - "description": "Whether to ignore type annotations on the variable of function expressions.", - "type": "boolean", - }, - "allowedNames": { - "description": "An array of function/method names that will not have their arguments or return values checked.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "explicit-member-accessibility": { - "create": [Function], - "defaultOptions": [ - { - "accessibility": "explicit", - }, - ], - "meta": { - "docs": { - "description": "Require explicit accessibility modifiers on class properties and methods", - "url": "https://typescript-eslint.io/rules/explicit-member-accessibility", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "addExplicitAccessibility": "Add '{{ type }}' accessibility modifier", - "missingAccessibility": "Missing accessibility modifier on {{type}} {{name}}.", - "unwantedPublicAccessibility": "Public accessibility modifier on {{type}} {{name}}.", - }, - "schema": [ - { - "$defs": { - "accessibilityLevel": { - "oneOf": [ - { - "description": "Always require an accessor.", - "enum": [ - "explicit", - ], - "type": "string", - }, - { - "description": "Require an accessor except when public.", - "enum": [ - "no-public", - ], - "type": "string", - }, - { - "description": "Never check whether there is an accessor.", - "enum": [ - "off", - ], - "type": "string", - }, - ], - }, - }, - "additionalProperties": false, - "properties": { - "accessibility": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "ignoredMethodNames": { - "items": { - "type": "string", - }, - "type": "array", - }, - "overrides": { - "additionalProperties": false, - "properties": { - "accessors": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "constructors": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "methods": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "parameterProperties": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - "properties": { - "$ref": "#/items/0/$defs/accessibilityLevel", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "explicit-module-boundary-types": { - "create": [Function], - "defaultOptions": [ - { - "allowArgumentsExplicitlyTypedAsAny": false, - "allowDirectConstAssertionInArrowFunctions": true, - "allowHigherOrderFunctions": true, - "allowTypedFunctionExpressions": true, - "allowedNames": [], - }, - ], - "meta": { - "docs": { - "description": "Require explicit return and argument types on exported functions' and classes' public class methods", - "url": "https://typescript-eslint.io/rules/explicit-module-boundary-types", - }, - "messages": { - "anyTypedArg": "Argument '{{name}}' should be typed with a non-any type.", - "anyTypedArgUnnamed": "{{type}} argument should be typed with a non-any type.", - "missingArgType": "Argument '{{name}}' should be typed.", - "missingArgTypeUnnamed": "{{type}} argument should be typed.", - "missingReturnType": "Missing return type on function.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowArgumentsExplicitlyTypedAsAny": { - "description": "Whether to ignore arguments that are explicitly typed as \`any\`.", - "type": "boolean", - }, - "allowDirectConstAssertionInArrowFunctions": { - "description": "Whether to ignore return type annotations on body-less arrow functions that return an \`as const\` type assertion. -You must still type the parameters of the function.", - "type": "boolean", - }, - "allowHigherOrderFunctions": { - "description": "Whether to ignore return type annotations on functions immediately returning another function expression. -You must still type the parameters of the function.", - "type": "boolean", - }, - "allowTypedFunctionExpressions": { - "description": "Whether to ignore type annotations on the variable of a function expression.", - "type": "boolean", - }, - "allowedNames": { - "description": "An array of function/method names that will not have their arguments or return values checked.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "func-call-spacing": { - "create": [Function], - "defaultOptions": [ - "never", - {}, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow spacing between function identifiers and their invocations", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/func-call-spacing", - }, - "fixable": "whitespace", - "messages": { - "missing": "Missing space between function name and paren.", - "unexpectedNewline": "Unexpected newline between function name and paren.", - "unexpectedWhitespace": "Unexpected whitespace between function name and paren.", - }, - "replacedBy": [ - "@stylistic/ts/func-call-spacing", - ], - "schema": { - "anyOf": [ - { - "items": [ - { - "enum": [ - "never", - ], - "type": "string", - }, - ], - "maxItems": 1, - "minItems": 0, - "type": "array", - }, - { - "items": [ - { - "enum": [ - "always", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "allowNewlines": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - ], - }, - "type": "layout", - }, - }, - "indent": { - "create": [Function], - "defaultOptions": [ - 4, - { - "SwitchCase": 1, - "flatTernaryExpressions": false, - "ignoredNodes": [], - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent indentation", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/indent", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "wrongIndentation": "Expected indentation of {{expected}} but found {{actual}}.", - }, - "replacedBy": [ - "@stylistic/ts/indent", - ], - "schema": [ - { - "oneOf": [ - { - "enum": [ - "tab", - ], - }, - { - "minimum": 0, - "type": "integer", - }, - ], - }, - { - "additionalProperties": false, - "properties": { - "ArrayExpression": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "CallExpression": { - "additionalProperties": false, - "properties": { - "arguments": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - "FunctionDeclaration": { - "additionalProperties": false, - "properties": { - "body": { - "minimum": 0, - "type": "integer", - }, - "parameters": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - "FunctionExpression": { - "additionalProperties": false, - "properties": { - "body": { - "minimum": 0, - "type": "integer", - }, - "parameters": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - "ImportDeclaration": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "MemberExpression": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "off", - ], - }, - ], - }, - "ObjectExpression": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "StaticBlock": { - "additionalProperties": false, - "properties": { - "body": { - "minimum": 0, - "type": "integer", - }, - }, - "type": "object", - }, - "SwitchCase": { - "default": 0, - "minimum": 0, - "type": "integer", - }, - "VariableDeclarator": { - "oneOf": [ - { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - { - "additionalProperties": false, - "properties": { - "const": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "let": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - "var": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "first", - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - ], - }, - "flatTernaryExpressions": { - "default": false, - "type": "boolean", - }, - "ignoreComments": { - "default": false, - "type": "boolean", - }, - "ignoredNodes": { - "items": { - "not": { - "pattern": ":exit$", - }, - "type": "string", - }, - "type": "array", - }, - "offsetTernaryExpressions": { - "default": false, - "type": "boolean", - }, - "outerIIFEBody": { - "oneOf": [ - { - "minimum": 0, - "type": "integer", - }, - { - "enum": [ - "off", - ], - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "init-declarations": { - "create": [Function], - "defaultOptions": [ - "always", - ], - "meta": { - "docs": { - "description": "Require or disallow initialization in variable declarations", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/init-declarations", - }, - "hasSuggestions": undefined, - "messages": { - "initialized": "Variable '{{idName}}' should be initialized on declaration.", - "notInitialized": "Variable '{{idName}}' should not be initialized on declaration.", - }, - "schema": { - "anyOf": [ - { - "items": [ - { - "enum": [ - "always", - ], - }, - ], - "maxItems": 1, - "minItems": 0, - "type": "array", - }, - { - "items": [ - { - "enum": [ - "never", - ], - }, - { - "additionalProperties": false, - "properties": { - "ignoreForLoopInit": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - ], - }, - "type": "suggestion", - }, - }, - "key-spacing": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing between property names and type annotations in types and interfaces", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/key-spacing", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "extraKey": "Extra space after {{computed}}key '{{key}}'.", - "extraValue": "Extra space before value for {{computed}}key '{{key}}'.", - "missingKey": "Missing space after {{computed}}key '{{key}}'.", - "missingValue": "Missing space before value for {{computed}}key '{{key}}'.", - }, - "replacedBy": [ - "@stylistic/ts/key-spacing", - ], - "schema": [ - { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "align": { - "anyOf": [ - { - "enum": [ - "colon", - "value", - ], - }, - { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - "on": { - "enum": [ - "colon", - "value", - ], - }, - }, - "type": "object", - }, - ], - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "multiLine": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "align": { - "anyOf": [ - { - "enum": [ - "colon", - "value", - ], - }, - { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - "on": { - "enum": [ - "colon", - "value", - ], - }, - }, - "type": "object", - }, - ], - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - "singleLine": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "align": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - "on": { - "enum": [ - "colon", - "value", - ], - }, - }, - "type": "object", - }, - "multiLine": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - "singleLine": { - "additionalProperties": false, - "properties": { - "afterColon": { - "type": "boolean", - }, - "beforeColon": { - "type": "boolean", - }, - "mode": { - "enum": [ - "strict", - "minimum", - ], - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "layout", - }, - }, - "keyword-spacing": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing before and after keywords", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/keyword-spacing", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "expectedAfter": "Expected space(s) after "{{value}}".", - "expectedBefore": "Expected space(s) before "{{value}}".", - "unexpectedAfter": "Unexpected space(s) after "{{value}}".", - "unexpectedBefore": "Unexpected space(s) before "{{value}}".", - }, - "replacedBy": [ - "@stylistic/ts/keyword-spacing", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "after": { - "default": true, - "type": "boolean", - }, - "before": { - "default": true, - "type": "boolean", - }, - "overrides": { - "additionalProperties": false, - "properties": { - "abstract": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "as": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "async": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "await": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "boolean": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "break": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "byte": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "case": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "catch": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "char": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "class": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "const": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "continue": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "debugger": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "default": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "delete": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "do": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "double": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "else": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "enum": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "export": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "extends": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "false": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "final": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "finally": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "float": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "for": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "from": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "function": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "get": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "goto": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "if": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "implements": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "import": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "in": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "instanceof": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "int": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "interface": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "let": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "long": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "native": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "new": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "null": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "of": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "package": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "private": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "protected": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "public": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "return": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "set": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "short": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "static": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "super": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "switch": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "synchronized": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "this": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "throw": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "throws": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "transient": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "true": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "try": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "type": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "typeof": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "var": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "void": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "volatile": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "while": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "with": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - "yield": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "lines-around-comment": { - "create": [Function], - "defaultOptions": [ - { - "beforeBlockComment": true, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require empty lines around comments", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/lines-around-comment", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "after": "Expected line after comment.", - "before": "Expected line before comment.", - }, - "replacedBy": [ - "@stylistic/ts/lines-around-comment", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "afterBlockComment": { - "default": false, - "type": "boolean", - }, - "afterLineComment": { - "default": false, - "type": "boolean", - }, - "allowArrayEnd": { - "type": "boolean", - }, - "allowArrayStart": { - "type": "boolean", - }, - "allowBlockEnd": { - "default": false, - "type": "boolean", - }, - "allowBlockStart": { - "default": false, - "type": "boolean", - }, - "allowClassEnd": { - "type": "boolean", - }, - "allowClassStart": { - "type": "boolean", - }, - "allowEnumEnd": { - "type": "boolean", - }, - "allowEnumStart": { - "type": "boolean", - }, - "allowInterfaceEnd": { - "type": "boolean", - }, - "allowInterfaceStart": { - "type": "boolean", - }, - "allowModuleEnd": { - "type": "boolean", - }, - "allowModuleStart": { - "type": "boolean", - }, - "allowObjectEnd": { - "type": "boolean", - }, - "allowObjectStart": { - "type": "boolean", - }, - "allowTypeEnd": { - "type": "boolean", - }, - "allowTypeStart": { - "type": "boolean", - }, - "applyDefaultIgnorePatterns": { - "type": "boolean", - }, - "beforeBlockComment": { - "default": true, - "type": "boolean", - }, - "beforeLineComment": { - "default": false, - "type": "boolean", - }, - "ignorePattern": { - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "lines-between-class-members": { - "create": [Function], - "defaultOptions": [ - "always", - { - "exceptAfterOverload": true, - "exceptAfterSingleLine": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow an empty line between class members", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/lines-between-class-members", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "always": "Expected blank line between class members.", - "never": "Unexpected blank line between class members.", - }, - "replacedBy": [ - "@stylistic/ts/lines-between-class-members", - ], - "schema": [ - { - "anyOf": [ - { - "additionalProperties": false, - "properties": { - "enforce": { - "items": { - "additionalProperties": false, - "properties": { - "blankLine": { - "enum": [ - "always", - "never", - ], - }, - "next": { - "enum": [ - "method", - "field", - "*", - ], - }, - "prev": { - "enum": [ - "method", - "field", - "*", - ], - }, - }, - "required": [ - "blankLine", - "prev", - "next", - ], - "type": "object", - }, - "minItems": 1, - "type": "array", - }, - }, - "required": [ - "enforce", - ], - "type": "object", - }, - { - "enum": [ - "always", - "never", - ], - }, - ], - }, - { - "additionalProperties": false, - "properties": { - "exceptAfterOverload": { - "default": true, - "type": "boolean", - }, - "exceptAfterSingleLine": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "max-params": { - "create": [Function], - "defaultOptions": [ - { - "countVoidThis": false, - "max": 3, - }, - ], - "meta": { - "docs": { - "description": "Enforce a maximum number of parameters in function definitions", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/max-params", - }, - "messages": { - "exceed": "{{name}} has too many parameters ({{count}}). Maximum allowed is {{max}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "countVoidThis": { - "type": "boolean", - }, - "max": { - "minimum": 0, - "type": "integer", - }, - "maximum": { - "minimum": 0, - "type": "integer", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "member-delimiter-style": { - "create": [Function], - "defaultOptions": [ - { - "multiline": { - "delimiter": "semi", - "requireLast": true, - }, - "multilineDetection": "brackets", - "singleline": { - "delimiter": "semi", - "requireLast": false, - }, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require a specific member delimiter style for interfaces and type literals", - "url": "https://typescript-eslint.io/rules/member-delimiter-style", - }, - "fixable": "whitespace", - "messages": { - "expectedComma": "Expected a comma.", - "expectedSemi": "Expected a semicolon.", - "unexpectedComma": "Unexpected separator (,).", - "unexpectedSemi": "Unexpected separator (;).", - }, - "replacedBy": [ - "@stylistic/ts/member-delimiter-style", - ], - "schema": [ - { - "$defs": { - "delimiterConfig": { - "additionalProperties": false, - "properties": { - "multiline": { - "additionalProperties": false, - "properties": { - "delimiter": { - "$ref": "#/items/0/$defs/multiLineOption", - }, - "requireLast": { - "type": "boolean", - }, - }, - "type": "object", - }, - "singleline": { - "additionalProperties": false, - "properties": { - "delimiter": { - "$ref": "#/items/0/$defs/singleLineOption", - }, - "requireLast": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - "multiLineOption": { - "enum": [ - "none", - "semi", - "comma", - ], - "type": "string", - }, - "singleLineOption": { - "enum": [ - "semi", - "comma", - ], - "type": "string", - }, - }, - "additionalProperties": false, - "properties": { - "multiline": { - "additionalProperties": false, - "properties": { - "delimiter": { - "$ref": "#/items/0/$defs/multiLineOption", - }, - "requireLast": { - "type": "boolean", - }, - }, - "type": "object", - }, - "multilineDetection": { - "enum": [ - "brackets", - "last-member", - ], - "type": "string", - }, - "overrides": { - "additionalProperties": false, - "properties": { - "interface": { - "$ref": "#/items/0/$defs/delimiterConfig", - }, - "typeLiteral": { - "$ref": "#/items/0/$defs/delimiterConfig", - }, - }, - "type": "object", - }, - "singleline": { - "additionalProperties": false, - "properties": { - "delimiter": { - "$ref": "#/items/0/$defs/singleLineOption", - }, - "requireLast": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "member-ordering": { - "create": [Function], - "defaultOptions": [ - { - "default": { - "memberTypes": [ - "signature", - "call-signature", - "public-static-field", - "protected-static-field", - "private-static-field", - "#private-static-field", - "public-decorated-field", - "protected-decorated-field", - "private-decorated-field", - "public-instance-field", - "protected-instance-field", - "private-instance-field", - "#private-instance-field", - "public-abstract-field", - "protected-abstract-field", - "public-field", - "protected-field", - "private-field", - "#private-field", - "static-field", - "instance-field", - "abstract-field", - "decorated-field", - "field", - "static-initialization", - "public-constructor", - "protected-constructor", - "private-constructor", - "constructor", - "public-static-accessor", - "protected-static-accessor", - "private-static-accessor", - "#private-static-accessor", - "public-decorated-accessor", - "protected-decorated-accessor", - "private-decorated-accessor", - "public-instance-accessor", - "protected-instance-accessor", - "private-instance-accessor", - "#private-instance-accessor", - "public-abstract-accessor", - "protected-abstract-accessor", - "public-accessor", - "protected-accessor", - "private-accessor", - "#private-accessor", - "static-accessor", - "instance-accessor", - "abstract-accessor", - "decorated-accessor", - "accessor", - "public-static-get", - "protected-static-get", - "private-static-get", - "#private-static-get", - "public-decorated-get", - "protected-decorated-get", - "private-decorated-get", - "public-instance-get", - "protected-instance-get", - "private-instance-get", - "#private-instance-get", - "public-abstract-get", - "protected-abstract-get", - "public-get", - "protected-get", - "private-get", - "#private-get", - "static-get", - "instance-get", - "abstract-get", - "decorated-get", - "get", - "public-static-set", - "protected-static-set", - "private-static-set", - "#private-static-set", - "public-decorated-set", - "protected-decorated-set", - "private-decorated-set", - "public-instance-set", - "protected-instance-set", - "private-instance-set", - "#private-instance-set", - "public-abstract-set", - "protected-abstract-set", - "public-set", - "protected-set", - "private-set", - "#private-set", - "static-set", - "instance-set", - "abstract-set", - "decorated-set", - "set", - "public-static-method", - "protected-static-method", - "private-static-method", - "#private-static-method", - "public-decorated-method", - "protected-decorated-method", - "private-decorated-method", - "public-instance-method", - "protected-instance-method", - "private-instance-method", - "#private-instance-method", - "public-abstract-method", - "protected-abstract-method", - "public-method", - "protected-method", - "private-method", - "#private-method", - "static-method", - "instance-method", - "abstract-method", - "decorated-method", - "method", - ], - }, - }, - ], - "meta": { - "docs": { - "description": "Require a consistent member declaration order", - "url": "https://typescript-eslint.io/rules/member-ordering", - }, - "messages": { - "incorrectGroupOrder": "Member {{name}} should be declared before all {{rank}} definitions.", - "incorrectOrder": "Member {{member}} should be declared before member {{beforeMember}}.", - "incorrectRequiredMembersOrder": "Member {{member}} should be declared after all {{optionalOrRequired}} members.", - }, - "schema": [ - { - "$defs": { - "allItems": { - "enum": [ - "readonly-signature", - "signature", - "readonly-field", - "public-readonly-field", - "public-decorated-readonly-field", - "decorated-readonly-field", - "static-readonly-field", - "public-static-readonly-field", - "instance-readonly-field", - "public-instance-readonly-field", - "abstract-readonly-field", - "public-abstract-readonly-field", - "protected-readonly-field", - "protected-decorated-readonly-field", - "protected-static-readonly-field", - "protected-instance-readonly-field", - "protected-abstract-readonly-field", - "private-readonly-field", - "private-decorated-readonly-field", - "private-static-readonly-field", - "private-instance-readonly-field", - "#private-readonly-field", - "#private-static-readonly-field", - "#private-instance-readonly-field", - "field", - "public-field", - "public-decorated-field", - "decorated-field", - "static-field", - "public-static-field", - "instance-field", - "public-instance-field", - "abstract-field", - "public-abstract-field", - "protected-field", - "protected-decorated-field", - "protected-static-field", - "protected-instance-field", - "protected-abstract-field", - "private-field", - "private-decorated-field", - "private-static-field", - "private-instance-field", - "#private-field", - "#private-static-field", - "#private-instance-field", - "method", - "public-method", - "public-decorated-method", - "decorated-method", - "static-method", - "public-static-method", - "instance-method", - "public-instance-method", - "abstract-method", - "public-abstract-method", - "protected-method", - "protected-decorated-method", - "protected-static-method", - "protected-instance-method", - "protected-abstract-method", - "private-method", - "private-decorated-method", - "private-static-method", - "private-instance-method", - "#private-method", - "#private-static-method", - "#private-instance-method", - "call-signature", - "constructor", - "public-constructor", - "protected-constructor", - "private-constructor", - "accessor", - "public-accessor", - "public-decorated-accessor", - "decorated-accessor", - "static-accessor", - "public-static-accessor", - "instance-accessor", - "public-instance-accessor", - "abstract-accessor", - "public-abstract-accessor", - "protected-accessor", - "protected-decorated-accessor", - "protected-static-accessor", - "protected-instance-accessor", - "protected-abstract-accessor", - "private-accessor", - "private-decorated-accessor", - "private-static-accessor", - "private-instance-accessor", - "#private-accessor", - "#private-static-accessor", - "#private-instance-accessor", - "get", - "public-get", - "public-decorated-get", - "decorated-get", - "static-get", - "public-static-get", - "instance-get", - "public-instance-get", - "abstract-get", - "public-abstract-get", - "protected-get", - "protected-decorated-get", - "protected-static-get", - "protected-instance-get", - "protected-abstract-get", - "private-get", - "private-decorated-get", - "private-static-get", - "private-instance-get", - "#private-get", - "#private-static-get", - "#private-instance-get", - "set", - "public-set", - "public-decorated-set", - "decorated-set", - "static-set", - "public-static-set", - "instance-set", - "public-instance-set", - "abstract-set", - "public-abstract-set", - "protected-set", - "protected-decorated-set", - "protected-static-set", - "protected-instance-set", - "protected-abstract-set", - "private-set", - "private-decorated-set", - "private-static-set", - "private-instance-set", - "#private-set", - "#private-static-set", - "#private-instance-set", - "static-initialization", - "static-static-initialization", - "public-static-static-initialization", - "instance-static-initialization", - "public-instance-static-initialization", - "abstract-static-initialization", - "public-abstract-static-initialization", - "protected-static-static-initialization", - "protected-instance-static-initialization", - "protected-abstract-static-initialization", - "private-static-static-initialization", - "private-instance-static-initialization", - "#private-static-static-initialization", - "#private-instance-static-initialization", - ], - "type": "string", - }, - "baseConfig": { - "oneOf": [ - { - "enum": [ - "never", - ], - "type": "string", - }, - { - "items": { - "oneOf": [ - { - "$ref": "#/items/0/$defs/allItems", - }, - { - "items": { - "$ref": "#/items/0/$defs/allItems", - }, - "type": "array", - }, - ], - }, - "type": "array", - }, - { - "additionalProperties": false, - "properties": { - "memberTypes": { - "oneOf": [ - { - "items": { - "oneOf": [ - { - "$ref": "#/items/0/$defs/allItems", - }, - { - "items": { - "$ref": "#/items/0/$defs/allItems", - }, - "type": "array", - }, - ], - }, - "type": "array", - }, - { - "enum": [ - "never", - ], - "type": "string", - }, - ], - }, - "optionalityOrder": { - "$ref": "#/items/0/$defs/optionalityOrderOptions", - }, - "order": { - "$ref": "#/items/0/$defs/orderOptions", - }, - }, - "type": "object", - }, - ], - }, - "optionalityOrderOptions": { - "enum": [ - "optional-first", - "required-first", - ], - "type": "string", - }, - "orderOptions": { - "enum": [ - "alphabetically", - "alphabetically-case-insensitive", - "as-written", - "natural", - "natural-case-insensitive", - ], - "type": "string", - }, - "typeItems": { - "enum": [ - "readonly-signature", - "signature", - "readonly-field", - "field", - "method", - "constructor", - ], - "type": "string", - }, - "typesConfig": { - "oneOf": [ - { - "enum": [ - "never", - ], - "type": "string", - }, - { - "items": { - "oneOf": [ - { - "$ref": "#/items/0/$defs/typeItems", - }, - { - "items": { - "$ref": "#/items/0/$defs/typeItems", - }, - "type": "array", - }, - ], - }, - "type": "array", - }, - { - "additionalProperties": false, - "properties": { - "memberTypes": { - "oneOf": [ - { - "items": { - "oneOf": [ - { - "$ref": "#/items/0/$defs/typeItems", - }, - { - "items": { - "$ref": "#/items/0/$defs/typeItems", - }, - "type": "array", - }, - ], - }, - "type": "array", - }, - { - "enum": [ - "never", - ], - "type": "string", - }, - ], - }, - "optionalityOrder": { - "$ref": "#/items/0/$defs/optionalityOrderOptions", - }, - "order": { - "$ref": "#/items/0/$defs/orderOptions", - }, - }, - "type": "object", - }, - ], - }, - }, - "additionalProperties": false, - "properties": { - "classExpressions": { - "$ref": "#/items/0/$defs/baseConfig", - }, - "classes": { - "$ref": "#/items/0/$defs/baseConfig", - }, - "default": { - "$ref": "#/items/0/$defs/baseConfig", - }, - "interfaces": { - "$ref": "#/items/0/$defs/typesConfig", - }, - "typeLiterals": { - "$ref": "#/items/0/$defs/typesConfig", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "method-signature-style": { - "create": [Function], - "defaultOptions": [ - "property", - ], - "meta": { - "docs": { - "description": "Enforce using a particular method signature syntax", - "url": "https://typescript-eslint.io/rules/method-signature-style", - }, - "fixable": "code", - "messages": { - "errorMethod": "Shorthand method signature is forbidden. Use a function property instead.", - "errorProperty": "Function property signature is forbidden. Use a method shorthand instead.", - }, - "schema": [ - { - "enum": [ - "property", - "method", - ], - "type": "string", - }, - ], - "type": "suggestion", - }, - }, - "naming-convention": { - "create": [Function], - "defaultOptions": [ - { - "format": [ - "camelCase", - ], - "leadingUnderscore": "allow", - "selector": "default", - "trailingUnderscore": "allow", - }, - { - "format": [ - "camelCase", - "PascalCase", - ], - "selector": "import", - }, - { - "format": [ - "camelCase", - "UPPER_CASE", - ], - "leadingUnderscore": "allow", - "selector": "variable", - "trailingUnderscore": "allow", - }, - { - "format": [ - "PascalCase", - ], - "selector": "typeLike", - }, - ], - "meta": { - "docs": { - "description": "Enforce naming conventions for everything across a codebase", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/naming-convention", - }, - "messages": { - "doesNotMatchFormat": "{{type}} name \`{{name}}\` must match one of the following formats: {{formats}}", - "doesNotMatchFormatTrimmed": "{{type}} name \`{{name}}\` trimmed as \`{{processedName}}\` must match one of the following formats: {{formats}}", - "missingAffix": "{{type}} name \`{{name}}\` must have one of the following {{position}}es: {{affixes}}", - "missingUnderscore": "{{type}} name \`{{name}}\` must have {{count}} {{position}} underscore(s).", - "satisfyCustom": "{{type}} name \`{{name}}\` must {{regexMatch}} the RegExp: {{regex}}", - "unexpectedUnderscore": "{{type}} name \`{{name}}\` must not have a {{position}} underscore.", - }, - "schema": { - "$defs": { - "formatOptionsConfig": { - "oneOf": [ - { - "additionalItems": false, - "items": { - "$ref": "#/$defs/predefinedFormats", - }, - "type": "array", - }, - { - "type": "null", - }, - ], - }, - "matchRegexConfig": { - "additionalProperties": false, - "properties": { - "match": { - "type": "boolean", - }, - "regex": { - "type": "string", - }, - }, - "required": [ - "match", - "regex", - ], - "type": "object", - }, - "predefinedFormats": { - "enum": [ - "camelCase", - "strictCamelCase", - "PascalCase", - "StrictPascalCase", - "snake_case", - "UPPER_CASE", - ], - "type": "string", - }, - "prefixSuffixConfig": { - "additionalItems": false, - "items": { - "minLength": 1, - "type": "string", - }, - "type": "array", - }, - "typeModifiers": { - "enum": [ - "boolean", - "string", - "number", - "function", - "array", - ], - "type": "string", - }, - "underscoreOptions": { - "enum": [ - "forbid", - "allow", - "require", - "requireDouble", - "allowDouble", - "allowSingleOrDouble", - ], - "type": "string", - }, - }, - "additionalItems": false, - "items": { - "oneOf": [ - { - "additionalProperties": false, - "description": "Multiple selectors in one config", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "const", - "readonly", - "static", - "public", - "protected", - "private", - "#private", - "abstract", - "destructured", - "global", - "exported", - "unused", - "requiresQuotes", - "override", - "async", - "default", - "namespace", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "additionalItems": false, - "items": { - "enum": [ - "default", - "variableLike", - "memberLike", - "typeLike", - "method", - "property", - "accessor", - "variable", - "function", - "parameter", - "parameterProperty", - "classicAccessor", - "enumMember", - "classMethod", - "objectLiteralMethod", - "typeMethod", - "classProperty", - "objectLiteralProperty", - "typeProperty", - "autoAccessor", - "class", - "interface", - "typeAlias", - "enum", - "typeParameter", - "import", - ], - "type": "string", - }, - "type": "array", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'default'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "const", - "readonly", - "static", - "public", - "protected", - "private", - "#private", - "abstract", - "destructured", - "global", - "exported", - "unused", - "requiresQuotes", - "override", - "async", - "default", - "namespace", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "default", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'variableLike'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "unused", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "variableLike", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'variable'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "const", - "destructured", - "exported", - "global", - "unused", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "variable", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'function'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "exported", - "global", - "unused", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "function", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'parameter'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "destructured", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "parameter", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'memberLike'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "readonly", - "requiresQuotes", - "static", - "override", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "memberLike", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'classProperty'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "readonly", - "requiresQuotes", - "static", - "override", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "classProperty", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'objectLiteralProperty'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "public", - "requiresQuotes", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "objectLiteralProperty", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeProperty'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "public", - "readonly", - "requiresQuotes", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeProperty", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'parameterProperty'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "private", - "protected", - "public", - "readonly", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "parameterProperty", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'property'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "readonly", - "requiresQuotes", - "static", - "override", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "property", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'classMethod'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "classMethod", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'objectLiteralMethod'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "public", - "requiresQuotes", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "objectLiteralMethod", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeMethod'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "public", - "requiresQuotes", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeMethod", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'method'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "#private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - "async", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "method", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'classicAccessor'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "classicAccessor", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'autoAccessor'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "autoAccessor", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'accessor'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "private", - "protected", - "public", - "requiresQuotes", - "static", - "override", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "accessor", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "types": { - "additionalItems": false, - "items": { - "$ref": "#/$defs/typeModifiers", - }, - "type": "array", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'enumMember'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "requiresQuotes", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "enumMember", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeLike'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeLike", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'class'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "abstract", - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "class", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'interface'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "interface", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeAlias'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeAlias", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'enum'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "exported", - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "enum", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'typeParameter'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "unused", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "typeParameter", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - { - "additionalProperties": false, - "description": "Selector 'import'", - "properties": { - "custom": { - "$ref": "#/$defs/matchRegexConfig", - }, - "failureMessage": { - "type": "string", - }, - "filter": { - "oneOf": [ - { - "minLength": 1, - "type": "string", - }, - { - "$ref": "#/$defs/matchRegexConfig", - }, - ], - }, - "format": { - "$ref": "#/$defs/formatOptionsConfig", - }, - "leadingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - "modifiers": { - "additionalItems": false, - "items": { - "enum": [ - "default", - "namespace", - ], - "type": "string", - }, - "type": "array", - }, - "prefix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "selector": { - "enum": [ - "import", - ], - "type": "string", - }, - "suffix": { - "$ref": "#/$defs/prefixSuffixConfig", - }, - "trailingUnderscore": { - "$ref": "#/$defs/underscoreOptions", - }, - }, - "required": [ - "selector", - "format", - ], - "type": "object", - }, - ], - }, - "type": "array", - }, - "type": "suggestion", - }, - }, - "no-array-constructor": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow generic \`Array\` constructors", - "extendsBaseRule": true, - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-array-constructor", - }, - "fixable": "code", - "messages": { - "useLiteral": "The array literal notation [] is preferable.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-array-delete": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow using the \`delete\` operator on array values", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-array-delete", - }, - "hasSuggestions": true, - "messages": { - "noArrayDelete": "Using the \`delete\` operator with an array expression is unsafe.", - "useSplice": "Use \`array.splice()\` instead.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-base-to-string": { - "create": [Function], - "defaultOptions": [ - { - "ignoredTypeNames": [ - "Error", - "RegExp", - "URL", - "URLSearchParams", - ], - }, - ], - "meta": { - "docs": { - "description": "Require \`.toString()\` to only be called on objects which provide useful information when stringified", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-base-to-string", - }, - "messages": { - "baseToString": "'{{name}}' {{certainty}} evaluate to '[object Object]' when stringified.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoredTypeNames": { - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-confusing-non-null-assertion": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow non-null assertion in locations that may be confusing", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/no-confusing-non-null-assertion", - }, - "hasSuggestions": true, - "messages": { - "confusingAssign": "Confusing combinations of non-null assertion and equal test like "a! = b", which looks very similar to not equal "a != b".", - "confusingEqual": "Confusing combinations of non-null assertion and equal test like "a! == b", which looks very similar to not equal "a !== b".", - "notNeedInAssign": "Unnecessary non-null assertion (!) in assignment left hand.", - "notNeedInEqualTest": "Unnecessary non-null assertion (!) in equal test.", - "wrapUpLeft": "Wrap up left hand to avoid putting non-null assertion "!" and "=" together.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-confusing-void-expression": { - "create": [Function], - "defaultOptions": [ - { - "ignoreArrowShorthand": false, - "ignoreVoidOperator": false, - }, - ], - "meta": { - "docs": { - "description": "Require expressions of type void to appear in statement position", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-confusing-void-expression", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "invalidVoidExpr": "Placing a void expression inside another expression is forbidden. Move it to its own statement instead.", - "invalidVoidExprArrow": "Returning a void expression from an arrow function shorthand is forbidden. Please add braces to the arrow function.", - "invalidVoidExprArrowWrapVoid": "Void expressions returned from an arrow function shorthand must be marked explicitly with the \`void\` operator.", - "invalidVoidExprReturn": "Returning a void expression from a function is forbidden. Please move it before the \`return\` statement.", - "invalidVoidExprReturnLast": "Returning a void expression from a function is forbidden. Please remove the \`return\` statement.", - "invalidVoidExprReturnWrapVoid": "Void expressions returned from a function must be marked explicitly with the \`void\` operator.", - "invalidVoidExprWrapVoid": "Void expressions used inside another expression must be moved to its own statement or marked explicitly with the \`void\` operator.", - "voidExprWrapVoid": "Mark with an explicit \`void\` operator.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreArrowShorthand": { - "type": "boolean", - }, - "ignoreVoidOperator": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-dupe-class-members": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow duplicate class members", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-dupe-class-members", - }, - "hasSuggestions": undefined, - "messages": { - "unexpected": "Duplicate name '{{name}}'.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-duplicate-enum-values": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow duplicate enum member values", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-duplicate-enum-values", - }, - "hasSuggestions": false, - "messages": { - "duplicateValue": "Duplicate enum member value {{value}}.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-duplicate-type-constituents": { - "create": [Function], - "defaultOptions": [ - { - "ignoreIntersections": false, - "ignoreUnions": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow duplicate constituents of union or intersection types", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-duplicate-type-constituents", - }, - "fixable": "code", - "messages": { - "duplicate": "{{type}} type constituent is duplicated with {{previous}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreIntersections": { - "type": "boolean", - }, - "ignoreUnions": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-dynamic-delete": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow using the \`delete\` operator on computed key expressions", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-dynamic-delete", - }, - "fixable": "code", - "messages": { - "dynamicDelete": "Do not delete dynamically computed property keys.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-empty-function": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - }, - ], - "meta": { - "docs": { - "description": "Disallow empty functions", - "extendsBaseRule": true, - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/no-empty-function", - }, - "hasSuggestions": undefined, - "messages": { - "unexpected": "Unexpected empty {{name}}.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "enum": [ - "functions", - "arrowFunctions", - "generatorFunctions", - "methods", - "generatorMethods", - "getters", - "setters", - "constructors", - "private-constructors", - "protected-constructors", - "asyncFunctions", - "asyncMethods", - "decoratedFunctions", - "overrideMethods", - ], - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-empty-interface": { - "create": [Function], - "defaultOptions": [ - { - "allowSingleExtends": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow the declaration of empty interfaces", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/no-empty-interface", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "noEmpty": "An empty interface is equivalent to \`{}\`.", - "noEmptyWithSuper": "An interface declaring no members is equivalent to its supertype.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowSingleExtends": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-explicit-any": { - "create": [Function], - "defaultOptions": [ - { - "fixToUnknown": false, - "ignoreRestArgs": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow the \`any\` type", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-explicit-any", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "suggestNever": "Use \`never\` instead, this is useful when instantiating generic type parameters that you don't need to know the type of.", - "suggestUnknown": "Use \`unknown\` instead, this will force you to explicitly, and safely assert the type is correct.", - "unexpectedAny": "Unexpected any. Specify a different type.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "fixToUnknown": { - "description": "Whether to enable auto-fixing in which the \`any\` type is converted to the \`unknown\` type.", - "type": "boolean", - }, - "ignoreRestArgs": { - "description": "Whether to ignore rest parameter arrays.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-extra-non-null-assertion": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow extra non-null assertions", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-extra-non-null-assertion", - }, - "fixable": "code", - "messages": { - "noExtraNonNullAssertion": "Forbidden extra non-null assertion.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-extra-parens": { - "create": [Function], - "defaultOptions": [ - "all", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow unnecessary parentheses", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-extra-parens", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "unexpected": "Unnecessary parentheses around expression.", - }, - "replacedBy": [ - "@stylistic/ts/no-extra-parens", - ], - "schema": { - "anyOf": [ - { - "items": [ - { - "enum": [ - "functions", - ], - }, - ], - "maxItems": 1, - "minItems": 0, - "type": "array", - }, - { - "items": [ - { - "enum": [ - "all", - ], - }, - { - "additionalProperties": false, - "properties": { - "allowParensAfterCommentPattern": { - "type": "string", - }, - "conditionalAssign": { - "type": "boolean", - }, - "enforceForArrowConditionals": { - "type": "boolean", - }, - "enforceForFunctionPrototypeMethods": { - "type": "boolean", - }, - "enforceForNewInMemberExpressions": { - "type": "boolean", - }, - "enforceForSequenceExpressions": { - "type": "boolean", - }, - "ignoreJSX": { - "enum": [ - "none", - "all", - "single-line", - "multi-line", - ], - }, - "nestedBinaryExpressions": { - "type": "boolean", - }, - "returnAssign": { - "type": "boolean", - }, - "ternaryOperandBinaryExpressions": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - ], - }, - "type": "layout", - }, - }, - "no-extra-semi": { - "create": [Function], - "defaultOptions": [], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow unnecessary semicolons", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-extra-semi", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "unexpected": "Unnecessary semicolon.", - }, - "replacedBy": [ - "@stylistic/ts/no-extra-semi", - ], - "schema": [], - "type": "suggestion", - }, - }, - "no-extraneous-class": { - "create": [Function], - "defaultOptions": [ - { - "allowConstructorOnly": false, - "allowEmpty": false, - "allowStaticOnly": false, - "allowWithDecorator": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow classes used as namespaces", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-extraneous-class", - }, - "messages": { - "empty": "Unexpected empty class.", - "onlyConstructor": "Unexpected class with only a constructor.", - "onlyStatic": "Unexpected class with only static properties.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowConstructorOnly": { - "description": "Whether to allow extraneous classes that contain only a constructor.", - "type": "boolean", - }, - "allowEmpty": { - "description": "Whether to allow extraneous classes that have no body (i.e. are empty).", - "type": "boolean", - }, - "allowStaticOnly": { - "description": "Whether to allow extraneous classes that only contain static members.", - "type": "boolean", - }, - "allowWithDecorator": { - "description": "Whether to allow extraneous classes that include a decorator.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-floating-promises": { - "create": [Function], - "defaultOptions": [ - { - "ignoreIIFE": false, - "ignoreVoid": true, - }, - ], - "meta": { - "docs": { - "description": "Require Promise-like statements to be handled appropriately", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-floating-promises", - }, - "hasSuggestions": true, - "messages": { - "floating": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler.", - "floatingFixAwait": "Add await operator.", - "floatingFixVoid": "Add void operator to ignore.", - "floatingPromiseArray": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar.", - "floatingPromiseArrayVoid": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar, or explicitly marking the expression as ignored with the \`void\` operator.", - "floatingUselessRejectionHandler": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler. A rejection handler that is not a function will be ignored.", - "floatingUselessRejectionHandlerVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator. A rejection handler that is not a function will be ignored.", - "floatingVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreIIFE": { - "description": "Whether to ignore async IIFEs (Immediately Invoked Function Expressions).", - "type": "boolean", - }, - "ignoreVoid": { - "description": "Whether to ignore \`void\` expressions.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-for-in-array": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow iterating over an array with a for-in loop", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-for-in-array", - }, - "messages": { - "forInViolation": "For-in loops over arrays skips holes, returns indices as strings, and may visit the prototype chain or other enumerable properties. Use a more robust iteration method such as for-of or array.forEach instead.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-implied-eval": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow the use of \`eval()\`-like methods", - "extendsBaseRule": true, - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-implied-eval", - }, - "messages": { - "noFunctionConstructor": "Implied eval. Do not use the Function constructor to create functions.", - "noImpliedEvalError": "Implied eval. Consider passing a function.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-import-type-side-effects": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce the use of top-level import type qualifier when an import only has specifiers with inline type qualifiers", - "url": "https://typescript-eslint.io/rules/no-import-type-side-effects", - }, - "fixable": "code", - "messages": { - "useTopLevelQualifier": "TypeScript will only remove the inline type specifiers which will leave behind a side effect import at runtime. Convert this to a top-level type qualifier to properly remove the entire import.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-inferrable-types": { - "create": [Function], - "defaultOptions": [ - { - "ignoreParameters": false, - "ignoreProperties": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow explicit type declarations for variables or parameters initialized to a number, string, or boolean", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/no-inferrable-types", - }, - "fixable": "code", - "messages": { - "noInferrableType": "Type {{type}} trivially inferred from a {{type}} literal, remove type annotation.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreParameters": { - "type": "boolean", - }, - "ignoreProperties": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-invalid-this": { - "create": [Function], - "defaultOptions": [ - { - "capIsConstructor": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow \`this\` keywords outside of classes or class-like objects", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-invalid-this", - }, - "hasSuggestions": undefined, - "messages": { - "unexpectedThis": "Unexpected 'this'.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "capIsConstructor": { - "default": true, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-invalid-void-type": { - "create": [Function], - "defaultOptions": [ - { - "allowAsThisParameter": false, - "allowInGenericTypeArguments": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow \`void\` type outside of generic or return types", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-invalid-void-type", - }, - "messages": { - "invalidVoidForGeneric": "{{ generic }} may not have void as a type argument.", - "invalidVoidNotReturn": "void is only valid as a return type.", - "invalidVoidNotReturnOrGeneric": "void is only valid as a return type or generic type argument.", - "invalidVoidNotReturnOrThisParam": "void is only valid as return type or type of \`this\` parameter.", - "invalidVoidNotReturnOrThisParamOrGeneric": "void is only valid as a return type or generic type argument or the type of a \`this\` parameter.", - "invalidVoidUnionConstituent": "void is not valid as a constituent in a union type", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAsThisParameter": { - "type": "boolean", - }, - "allowInGenericTypeArguments": { - "oneOf": [ - { - "type": "boolean", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-loop-func": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow function declarations that contain unsafe references inside loop statements", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-loop-func", - }, - "hasSuggestions": undefined, - "messages": { - "unsafeRefs": "Function declared in a loop contains unsafe references to variable(s) {{ varNames }}.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-loss-of-precision": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow literal numbers that lose precision", - "extendsBaseRule": true, - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-loss-of-precision", - }, - "hasSuggestions": undefined, - "messages": { - "noLossOfPrecision": "This number literal will lose precision at runtime.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-magic-numbers": { - "create": [Function], - "defaultOptions": [ - { - "detectObjects": false, - "enforceConst": false, - "ignore": [], - "ignoreArrayIndexes": false, - "ignoreEnums": false, - "ignoreNumericLiteralTypes": false, - "ignoreReadonlyClassProperties": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow magic numbers", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-magic-numbers", - }, - "messages": { - "noMagic": "No magic number: {{raw}}.", - "useConst": "Number constants declarations must use 'const'.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "detectObjects": { - "default": false, - "type": "boolean", - }, - "enforceConst": { - "default": false, - "type": "boolean", - }, - "ignore": { - "items": { - "anyOf": [ - { - "type": "number", - }, - { - "pattern": "^[+-]?(?:0|[1-9][0-9]*)n$", - "type": "string", - }, - ], - }, - "type": "array", - "uniqueItems": true, - }, - "ignoreArrayIndexes": { - "default": false, - "type": "boolean", - }, - "ignoreClassFieldInitialValues": { - "default": false, - "type": "boolean", - }, - "ignoreDefaultValues": { - "default": false, - "type": "boolean", - }, - "ignoreEnums": { - "type": "boolean", - }, - "ignoreNumericLiteralTypes": { - "type": "boolean", - }, - "ignoreReadonlyClassProperties": { - "type": "boolean", - }, - "ignoreTypeIndexes": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-meaningless-void-operator": { - "create": [Function], - "defaultOptions": [ - { - "checkNever": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow the \`void\` operator except when used to discard a value", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-meaningless-void-operator", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "meaninglessVoidOperator": "void operator shouldn't be used on {{type}}; it should convey that a return value is being ignored", - "removeVoid": "Remove 'void'", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "checkNever": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-misused-new": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce valid definition of \`new\` and \`constructor\`", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-misused-new", - }, - "messages": { - "errorMessageClass": "Class cannot have method named \`new\`.", - "errorMessageInterface": "Interfaces cannot be constructed, only classes.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-misused-promises": { - "create": [Function], - "defaultOptions": [ - { - "checksConditionals": true, - "checksSpreads": true, - "checksVoidReturn": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow Promises in places not designed to handle them", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-misused-promises", - }, - "messages": { - "conditional": "Expected non-Promise value in a boolean conditional.", - "spread": "Expected a non-Promise value to be spreaded in an object.", - "voidReturnArgument": "Promise returned in function argument where a void return was expected.", - "voidReturnAttribute": "Promise-returning function provided to attribute where a void return was expected.", - "voidReturnProperty": "Promise-returning function provided to property where a void return was expected.", - "voidReturnReturnValue": "Promise-returning function provided to return value where a void return was expected.", - "voidReturnVariable": "Promise-returning function provided to variable where a void return was expected.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "checksConditionals": { - "type": "boolean", - }, - "checksSpreads": { - "type": "boolean", - }, - "checksVoidReturn": { - "oneOf": [ - { - "type": "boolean", - }, - { - "additionalProperties": false, - "properties": { - "arguments": { - "type": "boolean", - }, - "attributes": { - "type": "boolean", - }, - "properties": { - "type": "boolean", - }, - "returns": { - "type": "boolean", - }, - "variables": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-mixed-enums": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow enums from having both number and string members", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-mixed-enums", - }, - "messages": { - "mixed": "Mixing number and string enums can be confusing.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-namespace": { - "create": [Function], - "defaultOptions": [ - { - "allowDeclarations": false, - "allowDefinitionFiles": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow TypeScript namespaces", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-namespace", - }, - "messages": { - "moduleSyntaxIsPreferred": "ES2015 module syntax is preferred over namespaces.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowDeclarations": { - "description": "Whether to allow \`declare\` with custom TypeScript namespaces.", - "type": "boolean", - }, - "allowDefinitionFiles": { - "description": "Whether to allow \`declare\` with custom TypeScript namespaces inside definition files.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-non-null-asserted-nullish-coalescing": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow non-null assertions in the left operand of a nullish coalescing operator", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-non-null-asserted-nullish-coalescing", - }, - "hasSuggestions": true, - "messages": { - "noNonNullAssertedNullishCoalescing": "The nullish coalescing operator is designed to handle undefined and null - using a non-null assertion is not needed.", - "suggestRemovingNonNull": "Remove the non-null assertion.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-non-null-asserted-optional-chain": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow non-null assertions after an optional chain expression", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-non-null-asserted-optional-chain", - }, - "hasSuggestions": true, - "messages": { - "noNonNullOptionalChain": "Optional chain expressions can return undefined by design - using a non-null assertion is unsafe and wrong.", - "suggestRemovingNonNull": "You should remove the non-null assertion.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-non-null-assertion": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow non-null assertions using the \`!\` postfix operator", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-non-null-assertion", - }, - "hasSuggestions": true, - "messages": { - "noNonNull": "Forbidden non-null assertion.", - "suggestOptionalChain": "Consider using the optional chain operator \`?.\` instead. This operator includes runtime checks, so it is safer than the compile-only non-null assertion operator.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-redeclare": { - "create": [Function], - "defaultOptions": [ - { - "builtinGlobals": true, - "ignoreDeclarationMerge": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow variable redeclaration", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-redeclare", - }, - "messages": { - "redeclared": "'{{id}}' is already defined.", - "redeclaredAsBuiltin": "'{{id}}' is already defined as a built-in global variable.", - "redeclaredBySyntax": "'{{id}}' is already defined by a variable declaration.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "builtinGlobals": { - "type": "boolean", - }, - "ignoreDeclarationMerge": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-redundant-type-constituents": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow members of unions and intersections that do nothing or override type information", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-redundant-type-constituents", - }, - "messages": { - "literalOverridden": "{{literal}} is overridden by {{primitive}} in this union type.", - "overridden": "'{{typeName}}' is overridden by other types in this {{container}} type.", - "overrides": "'{{typeName}}' overrides all other types in this {{container}} type.", - "primitiveOverridden": "{{primitive}} is overridden by the {{literal}} in this intersection type.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-require-imports": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - }, - ], - "meta": { - "docs": { - "description": "Disallow invocation of \`require()\`", - "url": "https://typescript-eslint.io/rules/no-require-imports", - }, - "messages": { - "noRequireImports": "A \`require()\` style import is forbidden.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "description": "Patterns of import paths to allow requiring from.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-restricted-imports": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow specified modules when loaded by \`import\`", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-restricted-imports", - }, - "fixable": undefined, - "messages": { - "everything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted.", - "everythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted. {{customMessage}}", - "importName": "'{{importName}}' import from '{{importSource}}' is restricted.", - "importNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted. {{customMessage}}", - "path": "'{{importSource}}' import is restricted from being used.", - "pathWithCustomMessage": "'{{importSource}}' import is restricted from being used. {{customMessage}}", - "patternAndEverything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern.", - "patternAndEverythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", - "patternAndEverythingWithRegexImportName": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used.", - "patternAndEverythingWithRegexImportNameAndCustomMessage": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used. {{customMessage}}", - "patternAndImportName": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern.", - "patternAndImportNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", - "patternWithCustomMessage": "'{{importSource}}' import is restricted from being used by a pattern. {{customMessage}}", - "patterns": "'{{importSource}}' import is restricted from being used by a pattern.", - }, - "schema": { - "anyOf": [ - { - "items": { - "anyOf": [ - { - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "allowTypeImports": { - "description": "Disallow value imports, but allow type-only imports.", - "type": "boolean", - }, - "importNames": { - "items": { - "type": "string", - }, - "type": "array", - }, - "message": { - "minLength": 1, - "type": "string", - }, - "name": { - "type": "string", - }, - }, - "required": [ - "name", - ], - "type": "object", - }, - ], - }, - "type": "array", - "uniqueItems": true, - }, - { - "additionalItems": false, - "items": [ - { - "additionalProperties": false, - "properties": { - "paths": { - "items": { - "anyOf": [ - { - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "allowTypeImports": { - "description": "Disallow value imports, but allow type-only imports.", - "type": "boolean", - }, - "importNames": { - "items": { - "type": "string", - }, - "type": "array", - }, - "message": { - "minLength": 1, - "type": "string", - }, - "name": { - "type": "string", - }, - }, - "required": [ - "name", - ], - "type": "object", - }, - ], - }, - "type": "array", - "uniqueItems": true, - }, - "patterns": { - "anyOf": [ - { - "items": { - "type": "string", - }, - "type": "array", - "uniqueItems": true, - }, - { - "items": { - "additionalProperties": false, - "properties": { - "allowTypeImports": { - "description": "Disallow value imports, but allow type-only imports.", - "type": "boolean", - }, - "caseSensitive": { - "type": "boolean", - }, - "group": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - "importNamePattern": { - "type": "string", - }, - "importNames": { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - "message": { - "minLength": 1, - "type": "string", - }, - }, - "required": [ - "group", - ], - "type": "object", - }, - "type": "array", - "uniqueItems": true, - }, - ], - }, - }, - "type": "object", - }, - ], - "type": "array", - }, - ], - }, - "type": "suggestion", - }, - }, - "no-shadow": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - "builtinGlobals": false, - "hoist": "functions", - "ignoreFunctionTypeParameterNameValueShadow": true, - "ignoreOnInitialization": false, - "ignoreTypeValueShadow": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow variable declarations from shadowing variables declared in the outer scope", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-shadow", - }, - "messages": { - "noShadow": "'{{name}}' is already declared in the upper scope on line {{shadowedLine}} column {{shadowedColumn}}.", - "noShadowGlobal": "'{{name}}' is already a global variable.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "type": "string", - }, - "type": "array", - }, - "builtinGlobals": { - "type": "boolean", - }, - "hoist": { - "enum": [ - "all", - "functions", - "never", - ], - "type": "string", - }, - "ignoreFunctionTypeParameterNameValueShadow": { - "type": "boolean", - }, - "ignoreOnInitialization": { - "type": "boolean", - }, - "ignoreTypeValueShadow": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-this-alias": { - "create": [Function], - "defaultOptions": [ - { - "allowDestructuring": true, - "allowedNames": [], - }, - ], - "meta": { - "docs": { - "description": "Disallow aliasing \`this\`", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-this-alias", - }, - "messages": { - "thisAssignment": "Unexpected aliasing of 'this' to local variable.", - "thisDestructure": "Unexpected aliasing of members of 'this' to local variables.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowDestructuring": { - "description": "Whether to ignore destructurings, such as \`const { props, state } = this\`.", - "type": "boolean", - }, - "allowedNames": { - "description": "Names to ignore, such as ["self"] for \`const self = this;\`.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-throw-literal": { - "create": [Function], - "defaultOptions": [ - { - "allowThrowingAny": true, - "allowThrowingUnknown": true, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow throwing literals as exceptions", - "extendsBaseRule": true, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-throw-literal", - }, - "messages": { - "object": "Expected an error object to be thrown.", - "undef": "Do not throw undefined.", - }, - "replacedBy": [ - "@typescript-eslint/only-throw-error", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowThrowingAny": { - "type": "boolean", - }, - "allowThrowingUnknown": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "no-type-alias": { - "create": [Function], - "defaultOptions": [ - { - "allowAliases": "never", - "allowCallbacks": "never", - "allowConditionalTypes": "never", - "allowConstructors": "never", - "allowGenerics": "never", - "allowLiterals": "never", - "allowMappedTypes": "never", - "allowTupleTypes": "never", - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Disallow type aliases", - "url": "https://typescript-eslint.io/rules/no-type-alias", - }, - "messages": { - "noCompositionAlias": "{{typeName}} in {{compositionType}} types are not allowed.", - "noTypeAlias": "Type {{alias}} are not allowed.", - }, - "schema": [ - { - "$defs": { - "expandedOptions": { - "enum": [ - "always", - "never", - "in-unions", - "in-intersections", - "in-unions-and-intersections", - ], - "type": "string", - }, - "simpleOptions": { - "enum": [ - "always", - "never", - ], - "type": "string", - }, - }, - "additionalProperties": false, - "properties": { - "allowAliases": { - "$ref": "#/items/0/$defs/expandedOptions", - "description": "Whether to allow direct one-to-one type aliases.", - }, - "allowCallbacks": { - "$ref": "#/items/0/$defs/simpleOptions", - "description": "Whether to allow type aliases for callbacks.", - }, - "allowConditionalTypes": { - "$ref": "#/items/0/$defs/simpleOptions", - "description": "Whether to allow type aliases for conditional types.", - }, - "allowConstructors": { - "$ref": "#/items/0/$defs/simpleOptions", - "description": "Whether to allow type aliases with constructors.", - }, - "allowGenerics": { - "$ref": "#/items/0/$defs/simpleOptions", - "description": "Whether to allow type aliases with generic types.", - }, - "allowLiterals": { - "$ref": "#/items/0/$defs/expandedOptions", - "description": "Whether to allow type aliases with object literal types.", - }, - "allowMappedTypes": { - "$ref": "#/items/0/$defs/expandedOptions", - "description": "Whether to allow type aliases with mapped types.", - }, - "allowTupleTypes": { - "$ref": "#/items/0/$defs/expandedOptions", - "description": "Whether to allow type aliases with tuple types.", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unnecessary-boolean-literal-compare": { - "create": [Function], - "defaultOptions": [ - { - "allowComparingNullableBooleansToFalse": true, - "allowComparingNullableBooleansToTrue": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow unnecessary equality comparisons against boolean literals", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-boolean-literal-compare", - }, - "fixable": "code", - "messages": { - "comparingNullableToFalse": "This expression unnecessarily compares a nullable boolean value to false instead of using the ?? operator to provide a default.", - "comparingNullableToTrueDirect": "This expression unnecessarily compares a nullable boolean value to true instead of using it directly.", - "comparingNullableToTrueNegated": "This expression unnecessarily compares a nullable boolean value to true instead of negating it.", - "direct": "This expression unnecessarily compares a boolean value to a boolean instead of using it directly.", - "negated": "This expression unnecessarily compares a boolean value to a boolean instead of negating it.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowComparingNullableBooleansToFalse": { - "description": "Whether to allow comparisons between nullable boolean variables and \`false\`.", - "type": "boolean", - }, - "allowComparingNullableBooleansToTrue": { - "description": "Whether to allow comparisons between nullable boolean variables and \`true\`.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unnecessary-condition": { - "create": [Function], - "defaultOptions": [ - { - "allowConstantLoopConditions": false, - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow conditionals where the type is always truthy or always falsy", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-condition", - }, - "fixable": "code", - "messages": { - "alwaysFalsy": "Unnecessary conditional, value is always falsy.", - "alwaysFalsyFunc": "This callback should return a conditional, but return is always falsy.", - "alwaysNullish": "Unnecessary conditional, left-hand side of \`??\` operator is always \`null\` or \`undefined\`.", - "alwaysTruthy": "Unnecessary conditional, value is always truthy.", - "alwaysTruthyFunc": "This callback should return a conditional, but return is always truthy.", - "literalBooleanExpression": "Unnecessary conditional, both sides of the expression are literal values.", - "never": "Unnecessary conditional, value is \`never\`.", - "neverNullish": "Unnecessary conditional, expected left-hand side of \`??\` operator to be possibly null or undefined.", - "neverOptionalChain": "Unnecessary optional chain on a non-nullish value.", - "noOverlapBooleanExpression": "Unnecessary conditional, the types have no overlap.", - "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowConstantLoopConditions": { - "description": "Whether to ignore constant loop conditions, such as \`while (true)\`.", - "type": "boolean", - }, - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { - "description": "Whether to not error when running with a tsconfig that has strictNullChecks turned.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unnecessary-qualifier": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unnecessary namespace qualifiers", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-qualifier", - }, - "fixable": "code", - "messages": { - "unnecessaryQualifier": "Qualifier is unnecessary since '{{ name }}' is in scope.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-unnecessary-type-arguments": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow type arguments that are equal to the default", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-type-arguments", - }, - "fixable": "code", - "messages": { - "unnecessaryTypeParameter": "This is the default value for this type parameter, so it can be omitted.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-unnecessary-type-assertion": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "docs": { - "description": "Disallow type assertions that do not change the type of an expression", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unnecessary-type-assertion", - }, - "fixable": "code", - "messages": { - "contextuallyUnnecessary": "This assertion is unnecessary since the receiver accepts the original type of the expression.", - "unnecessaryAssertion": "This assertion is unnecessary since it does not change the type of the expression.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "typesToIgnore": { - "description": "A list of type names to ignore.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unnecessary-type-constraint": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unnecessary constraints on generic types", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-unnecessary-type-constraint", - }, - "hasSuggestions": true, - "messages": { - "removeUnnecessaryConstraint": "Remove the unnecessary \`{{constraint}}\` constraint.", - "unnecessaryConstraint": "Constraining the generic type \`{{name}}\` to \`{{constraint}}\` does nothing and is unnecessary.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-unsafe-argument": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow calling a function with a value with type \`any\`", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-argument", - }, - "messages": { - "unsafeArgument": "Unsafe argument of type \`{{sender}}\` assigned to a parameter of type \`{{receiver}}\`.", - "unsafeArraySpread": "Unsafe spread of an \`any\` array type.", - "unsafeSpread": "Unsafe spread of an \`any\` type.", - "unsafeTupleSpread": "Unsafe spread of a tuple type. The argument is of type \`{{sender}}\` and is assigned to a parameter of type \`{{receiver}}\`.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-assignment": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow assigning a value with type \`any\` to variables and properties", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-assignment", - }, - "messages": { - "anyAssignment": "Unsafe assignment of an \`any\` value.", - "anyAssignmentThis": "Unsafe assignment of an \`any\` value. \`this\` is typed as \`any\`. -You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", - "unsafeArrayPattern": "Unsafe array destructuring of an \`any\` array value.", - "unsafeArrayPatternFromTuple": "Unsafe array destructuring of a tuple element with an \`any\` value.", - "unsafeArraySpread": "Unsafe spread of an \`any\` value in an array.", - "unsafeAssignment": "Unsafe assignment of type {{sender}} to a variable of type {{receiver}}.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-call": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow calling a value with type \`any\`", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-call", - }, - "messages": { - "unsafeCall": "Unsafe call of an \`any\` typed value.", - "unsafeCallThis": "Unsafe call of an \`any\` typed value. \`this\` is typed as \`any\`. -You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", - "unsafeNew": "Unsafe construction of an any type value.", - "unsafeTemplateTag": "Unsafe any typed template tag.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-declaration-merging": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unsafe declaration merging", - "recommended": "recommended", - "requiresTypeChecking": false, - "url": "https://typescript-eslint.io/rules/no-unsafe-declaration-merging", - }, - "messages": { - "unsafeMerging": "Unsafe declaration merging between classes and interfaces.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-enum-comparison": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow comparing an enum value with a non-enum value", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-enum-comparison", - }, - "hasSuggestions": true, - "messages": { - "mismatchedCase": "The case statement does not have a shared enum type with the switch predicate.", - "mismatchedCondition": "The two values in this comparison do not have a shared enum type.", - "replaceValueWithEnum": "Replace with an enum value comparison.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-unsafe-member-access": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow member access on a value with type \`any\`", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-member-access", - }, - "messages": { - "unsafeComputedMemberAccess": "Computed name {{property}} resolves to an any value.", - "unsafeMemberExpression": "Unsafe member access {{property}} on an \`any\` value.", - "unsafeThisMemberExpression": "Unsafe member access {{property}} on an \`any\` value. \`this\` is typed as \`any\`. -You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-return": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow returning a value with type \`any\` from a function", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-return", - }, - "messages": { - "unsafeReturn": "Unsafe return of an \`{{type}}\` typed value.", - "unsafeReturnAssignment": "Unsafe return of type \`{{sender}}\` from function with return type \`{{receiver}}\`.", - "unsafeReturnThis": "Unsafe return of an \`{{type}}\` typed value. \`this\` is typed as \`any\`. -You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unsafe-unary-minus": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Require unary negation to take a number", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-unsafe-unary-minus", - }, - "messages": { - "unaryMinus": "Argument of unary negation should be assignable to number | bigint but is {{type}} instead.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-unused-expressions": { - "create": [Function], - "defaultOptions": [ - { - "allowShortCircuit": false, - "allowTaggedTemplates": false, - "allowTernary": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow unused expressions", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-unused-expressions", - }, - "hasSuggestions": undefined, - "messages": { - "unusedExpression": "Expected an assignment or function call and instead saw an expression.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowShortCircuit": { - "default": false, - "type": "boolean", - }, - "allowTaggedTemplates": { - "default": false, - "type": "boolean", - }, - "allowTernary": { - "default": false, - "type": "boolean", - }, - "enforceForJSX": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "no-unused-vars": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "docs": { - "description": "Disallow unused variables", - "extendsBaseRule": true, - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-unused-vars", - }, - "messages": { - "unusedVar": "'{{varName}}' is {{action}} but never used{{additional}}.", - }, - "schema": [ - { - "oneOf": [ - { - "enum": [ - "all", - "local", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "args": { - "enum": [ - "all", - "after-used", - "none", - ], - "type": "string", - }, - "argsIgnorePattern": { - "type": "string", - }, - "caughtErrors": { - "enum": [ - "all", - "none", - ], - "type": "string", - }, - "caughtErrorsIgnorePattern": { - "type": "string", - }, - "destructuredArrayIgnorePattern": { - "type": "string", - }, - "ignoreRestSiblings": { - "type": "boolean", - }, - "vars": { - "enum": [ - "all", - "local", - ], - "type": "string", - }, - "varsIgnorePattern": { - "type": "string", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "problem", - }, - }, - "no-use-before-define": { - "create": [Function], - "defaultOptions": [ - { - "allowNamedExports": false, - "classes": true, - "enums": true, - "functions": true, - "ignoreTypeReferences": true, - "typedefs": true, - "variables": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow the use of variables before they are defined", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/no-use-before-define", - }, - "messages": { - "noUseBeforeDefine": "'{{name}}' was used before it was defined.", - }, - "schema": [ - { - "oneOf": [ - { - "enum": [ - "nofunc", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "allowNamedExports": { - "type": "boolean", - }, - "classes": { - "type": "boolean", - }, - "enums": { - "type": "boolean", - }, - "functions": { - "type": "boolean", - }, - "ignoreTypeReferences": { - "type": "boolean", - }, - "typedefs": { - "type": "boolean", - }, - "variables": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "problem", - }, - }, - "no-useless-constructor": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unnecessary constructors", - "extendsBaseRule": true, - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/no-useless-constructor", - }, - "hasSuggestions": undefined, - "messages": { - "noUselessConstructor": "Useless constructor.", - }, - "schema": [], - "type": "problem", - }, - }, - "no-useless-empty-export": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow empty exports that don't change anything in a module file", - "url": "https://typescript-eslint.io/rules/no-useless-empty-export", - }, - "fixable": "code", - "hasSuggestions": false, - "messages": { - "uselessExport": "Empty export does nothing and can be removed.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-useless-template-literals": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow unnecessary template literals", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/no-useless-template-literals", - }, - "fixable": "code", - "messages": { - "noUselessTemplateLiteral": "Template literal expression is unnecessary and can be simplified.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "no-var-requires": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - }, - ], - "meta": { - "docs": { - "description": "Disallow \`require\` statements except in import statements", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/no-var-requires", - }, - "messages": { - "noVarReqs": "Require statement not part of import statement.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "description": "Patterns of import paths to allow requiring from.", - "items": { - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "non-nullable-type-assertion-style": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce non-null assertions over explicit type casts", - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/non-nullable-type-assertion-style", - }, - "fixable": "code", - "messages": { - "preferNonNullAssertion": "Use a ! assertion to more succinctly remove null and undefined from the type.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "object-curly-spacing": { - "create": [Function], - "defaultOptions": [ - "never", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing inside braces", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/object-curly-spacing", - }, - "fixable": "whitespace", - "messages": { - "requireSpaceAfter": "A space is required after '{{token}}'.", - "requireSpaceBefore": "A space is required before '{{token}}'.", - "unexpectedSpaceAfter": "There should be no space after '{{token}}'.", - "unexpectedSpaceBefore": "There should be no space before '{{token}}'.", - }, - "replacedBy": [ - "@stylistic/ts/object-curly-spacing", - ], - "schema": [ - { - "enum": [ - "always", - "never", - ], - }, - { - "additionalProperties": false, - "properties": { - "arraysInObjects": { - "type": "boolean", - }, - "objectsInObjects": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "only-throw-error": { - "create": [Function], - "defaultOptions": [ - { - "allowThrowingAny": true, - "allowThrowingUnknown": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow throwing non-\`Error\` values as exceptions", - "extendsBaseRule": "no-throw-literal", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/only-throw-error", - }, - "messages": { - "object": "Expected an error object to be thrown.", - "undef": "Do not throw undefined.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowThrowingAny": { - "type": "boolean", - }, - "allowThrowingUnknown": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "padding-line-between-statements": { - "create": [Function], - "defaultOptions": [], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow padding lines between statements", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/padding-line-between-statements", - }, - "fixable": "whitespace", - "hasSuggestions": false, - "messages": { - "expectedBlankLine": "Expected blank line before this statement.", - "unexpectedBlankLine": "Unexpected blank line before this statement.", - }, - "replacedBy": [ - "@stylistic/ts/padding-line-between-statements", - ], - "schema": { - "$defs": { - "paddingType": { - "enum": [ - "any", - "never", - "always", - ], - "type": "string", - }, - "statementType": { - "anyOf": [ - { - "enum": [ - "*", - "block-like", - "exports", - "require", - "directive", - "expression", - "iife", - "multiline-block-like", - "multiline-expression", - "multiline-const", - "multiline-let", - "multiline-var", - "singleline-const", - "singleline-let", - "singleline-var", - "block", - "empty", - "function", - "break", - "case", - "class", - "const", - "continue", - "debugger", - "default", - "do", - "export", - "for", - "if", - "import", - "let", - "return", - "switch", - "throw", - "try", - "var", - "while", - "with", - "interface", - "type", - ], - "type": "string", - }, - { - "additionalItems": false, - "items": { - "enum": [ - "*", - "block-like", - "exports", - "require", - "directive", - "expression", - "iife", - "multiline-block-like", - "multiline-expression", - "multiline-const", - "multiline-let", - "multiline-var", - "singleline-const", - "singleline-let", - "singleline-var", - "block", - "empty", - "function", - "break", - "case", - "class", - "const", - "continue", - "debugger", - "default", - "do", - "export", - "for", - "if", - "import", - "let", - "return", - "switch", - "throw", - "try", - "var", - "while", - "with", - "interface", - "type", - ], - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - }, - "additionalItems": false, - "items": { - "additionalProperties": false, - "properties": { - "blankLine": { - "$ref": "#/$defs/paddingType", - }, - "next": { - "$ref": "#/$defs/statementType", - }, - "prev": { - "$ref": "#/$defs/statementType", - }, - }, - "required": [ - "blankLine", - "prev", - "next", - ], - "type": "object", - }, - "type": "array", - }, - "type": "layout", - }, - }, - "parameter-properties": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - "prefer": "class-property", - }, - ], - "meta": { - "docs": { - "description": "Require or disallow parameter properties in class constructors", - "url": "https://typescript-eslint.io/rules/parameter-properties", - }, - "messages": { - "preferClassProperty": "Property {{parameter}} should be declared as a class property.", - "preferParameterProperty": "Property {{parameter}} should be declared as a parameter property.", - }, - "schema": [ - { - "$defs": { - "modifier": { - "enum": [ - "readonly", - "private", - "protected", - "public", - "private readonly", - "protected readonly", - "public readonly", - ], - "type": "string", - }, - }, - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "$ref": "#/items/0/$defs/modifier", - }, - "type": "array", - }, - "prefer": { - "enum": [ - "class-property", - "parameter-property", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "prefer-as-const": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce the use of \`as const\` over literal type", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/prefer-as-const", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "preferConstAssertion": "Expected a \`const\` instead of a literal type assertion.", - "variableConstAssertion": "Expected a \`const\` assertion instead of a literal type annotation.", - "variableSuggest": "You should use \`as const\` instead of type annotation.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-destructuring": { - "create": [Function], - "defaultOptions": [ - { - "AssignmentExpression": { - "array": true, - "object": true, - }, - "VariableDeclarator": { - "array": true, - "object": true, - }, - }, - {}, - ], - "meta": { - "docs": { - "description": "Require destructuring from arrays and/or objects", - "extendsBaseRule": true, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-destructuring", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "preferDestructuring": "Use {{type}} destructuring.", - }, - "schema": [ - { - "oneOf": [ - { - "additionalProperties": false, - "properties": { - "AssignmentExpression": { - "additionalProperties": false, - "properties": { - "array": { - "type": "boolean", - }, - "object": { - "type": "boolean", - }, - }, - "type": "object", - }, - "VariableDeclarator": { - "additionalProperties": false, - "properties": { - "array": { - "type": "boolean", - }, - "object": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "array": { - "type": "boolean", - }, - "object": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - }, - { - "properties": { - "enforceForDeclarationWithTypeAnnotation": { - "type": "boolean", - }, - "enforceForRenamedProperties": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-enum-initializers": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Require each enum member value to be explicitly initialized", - "url": "https://typescript-eslint.io/rules/prefer-enum-initializers", - }, - "hasSuggestions": true, - "messages": { - "defineInitializer": "The value of the member '{{ name }}' should be explicitly defined.", - "defineInitializerSuggestion": "Can be fixed to {{ name }} = {{ suggested }}", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-find": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce the use of Array.prototype.find() over Array.prototype.filter() followed by [0] when looking for a single result", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-find", - }, - "hasSuggestions": true, - "messages": { - "preferFind": "Prefer .find(...) instead of .filter(...)[0].", - "preferFindSuggestion": "Use .find(...) instead of .filter(...)[0].", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-for-of": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce the use of \`for-of\` loop over the standard \`for\` loop where possible", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/prefer-for-of", - }, - "messages": { - "preferForOf": "Expected a \`for-of\` loop instead of a \`for\` loop with this simple iteration.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-function-type": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce using function types instead of interfaces with call signatures", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/prefer-function-type", - }, - "fixable": "code", - "messages": { - "functionTypeOverCallableType": "{{ literalOrInterface }} only has a call signature, you should use a function type instead.", - "unexpectedThisOnFunctionOnlyInterface": "\`this\` refers to the function type '{{ interfaceName }}', did you intend to use a generic \`this\` parameter like \`(this: Self, ...) => Self\` instead?", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-includes": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce \`includes\` method over \`indexOf\` method", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-includes", - }, - "fixable": "code", - "messages": { - "preferIncludes": "Use 'includes()' method instead.", - "preferStringIncludes": "Use \`String#includes()\` method with a string instead.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-literal-enum-member": { - "create": [Function], - "defaultOptions": [ - { - "allowBitwiseExpressions": false, - }, - ], - "meta": { - "docs": { - "description": "Require all enum members to be literal values", - "recommended": "strict", - "requiresTypeChecking": false, - "url": "https://typescript-eslint.io/rules/prefer-literal-enum-member", - }, - "messages": { - "notLiteral": "Explicit enum value must only be a literal value (string, number, boolean, etc).", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowBitwiseExpressions": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-namespace-keyword": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Require using \`namespace\` keyword over \`module\` keyword to declare custom TypeScript modules", - "recommended": "stylistic", - "url": "https://typescript-eslint.io/rules/prefer-namespace-keyword", - }, - "fixable": "code", - "messages": { - "useNamespace": "Use 'namespace' instead of 'module' to declare custom TypeScript modules.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-nullish-coalescing": { - "create": [Function], - "defaultOptions": [ - { - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, - "ignoreConditionalTests": false, - "ignoreMixedLogicalExpressions": false, - "ignorePrimitives": { - "bigint": false, - "boolean": false, - "number": false, - "string": false, - }, - "ignoreTernaryTests": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce using the nullish coalescing operator instead of logical assignments or chaining", - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-nullish-coalescing", - }, - "hasSuggestions": true, - "messages": { - "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", - "preferNullishOverOr": "Prefer using nullish coalescing operator (\`??\`) instead of a logical or (\`||\`), as it is a safer operator.", - "preferNullishOverTernary": "Prefer using nullish coalescing operator (\`??\`) instead of a ternary expression, as it is simpler to read.", - "suggestNullish": "Fix to nullish coalescing operator (\`??\`).", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { - "type": "boolean", - }, - "ignoreConditionalTests": { - "type": "boolean", - }, - "ignoreMixedLogicalExpressions": { - "type": "boolean", - }, - "ignorePrimitives": { - "oneOf": [ - { - "properties": { - "bigint": { - "type": "boolean", - }, - "boolean": { - "type": "boolean", - }, - "number": { - "type": "boolean", - }, - "string": { - "type": "boolean", - }, - }, - "type": "object", - }, - { - "enum": [ - true, - ], - "type": "boolean", - }, - ], - }, - "ignoreTernaryTests": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-optional-chain": { - "create": [Function], - "defaultOptions": [ - { - "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": false, - "checkAny": true, - "checkBigInt": true, - "checkBoolean": true, - "checkNumber": true, - "checkString": true, - "checkUnknown": true, - "requireNullish": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce using concise optional chain expressions instead of chained logical ands, negated logical ors, or empty objects", - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-optional-chain", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "optionalChainSuggest": "Change to an optional chain.", - "preferOptionalChain": "Prefer using an optional chain expression instead, as it's more concise and easier to read.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": { - "description": "Allow autofixers that will change the return type of the expression. This option is considered unsafe as it may break the build.", - "type": "boolean", - }, - "checkAny": { - "description": "Check operands that are typed as \`any\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkBigInt": { - "description": "Check operands that are typed as \`bigint\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkBoolean": { - "description": "Check operands that are typed as \`boolean\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkNumber": { - "description": "Check operands that are typed as \`number\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkString": { - "description": "Check operands that are typed as \`string\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "checkUnknown": { - "description": "Check operands that are typed as \`unknown\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - "requireNullish": { - "description": "Skip operands that are not typed with \`null\` and/or \`undefined\` when inspecting "loose boolean" operands.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-promise-reject-errors": { - "create": [Function], - "defaultOptions": [ - { - "allowEmptyReject": false, - }, - ], - "meta": { - "docs": { - "description": "Require using Error objects as Promise rejection reasons", - "extendsBaseRule": true, - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-promise-reject-errors", - }, - "messages": { - "rejectAnError": "Expected the Promise rejection reason to be an Error.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowEmptyReject": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-readonly": { - "create": [Function], - "defaultOptions": [ - { - "onlyInlineLambdas": false, - }, - ], - "meta": { - "docs": { - "description": "Require private members to be marked as \`readonly\` if they're never modified outside of the constructor", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-readonly", - }, - "fixable": "code", - "messages": { - "preferReadonly": "Member '{{name}}' is never reassigned; mark it as \`readonly\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "onlyInlineLambdas": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-readonly-parameter-types": { - "create": [Function], - "defaultOptions": [ - { - "allow": [], - "checkParameterProperties": true, - "ignoreInferredTypes": false, - "treatMethodsAsReadonly": false, - }, - ], - "meta": { - "docs": { - "description": "Require function parameters to be typed as \`readonly\` to prevent accidental mutation of inputs", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-readonly-parameter-types", - }, - "messages": { - "shouldBeReadonly": "Parameter should be a read only type.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allow": { - "items": { - "oneOf": [ - { - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "from": { - "enum": [ - "file", - ], - "type": "string", - }, - "name": { - "oneOf": [ - { - "type": "string", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - "path": { - "type": "string", - }, - }, - "required": [ - "from", - "name", - ], - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "from": { - "enum": [ - "lib", - ], - "type": "string", - }, - "name": { - "oneOf": [ - { - "type": "string", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - }, - "required": [ - "from", - "name", - ], - "type": "object", - }, - { - "additionalProperties": false, - "properties": { - "from": { - "enum": [ - "package", - ], - "type": "string", - }, - "name": { - "oneOf": [ - { - "type": "string", - }, - { - "items": { - "type": "string", - }, - "minItems": 1, - "type": "array", - "uniqueItems": true, - }, - ], - }, - "package": { - "type": "string", - }, - }, - "required": [ - "from", - "name", - "package", - ], - "type": "object", - }, - ], - }, - "type": "array", - }, - "checkParameterProperties": { - "type": "boolean", - }, - "ignoreInferredTypes": { - "type": "boolean", - }, - "treatMethodsAsReadonly": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-reduce-type-parameter": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce using type parameter when calling \`Array#reduce\` instead of casting", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-reduce-type-parameter", - }, - "fixable": "code", - "messages": { - "preferTypeParameter": "Unnecessary cast: Array#reduce accepts a type parameter for the default value.", - }, - "schema": [], - "type": "problem", - }, - }, - "prefer-regexp-exec": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce \`RegExp#exec\` over \`String#match\` if no global flag is provided", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-regexp-exec", - }, - "fixable": "code", - "messages": { - "regExpExecOverStringMatch": "Use the \`RegExp#exec()\` method instead.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-return-this-type": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce that \`this\` is used when only \`this\` type is returned", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-return-this-type", - }, - "fixable": "code", - "messages": { - "useThisType": "Use \`this\` type instead.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "prefer-string-starts-ends-with": { - "create": [Function], - "defaultOptions": [ - { - "allowSingleElementEquality": "never", - }, - ], - "meta": { - "docs": { - "description": "Enforce using \`String#startsWith\` and \`String#endsWith\` over other equivalent methods of checking substrings", - "recommended": "stylistic", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/prefer-string-starts-ends-with", - }, - "fixable": "code", - "messages": { - "preferEndsWith": "Use the 'String#endsWith' method instead.", - "preferStartsWith": "Use 'String#startsWith' method instead.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowSingleElementEquality": { - "description": "Whether to allow equality checks against the first or last element of a string.", - "enum": [ - "always", - "never", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "prefer-ts-expect-error": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce using \`@ts-expect-error\` over \`@ts-ignore\`", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/prefer-ts-expect-error", - }, - "fixable": "code", - "messages": { - "preferExpectErrorComment": "Use "@ts-expect-error" to ensure an error is actually being suppressed.", - }, - "schema": [], - "type": "problem", - }, - }, - "promise-function-async": { - "create": [Function], - "defaultOptions": [ - { - "allowAny": true, - "allowedPromiseNames": [], - "checkArrowFunctions": true, - "checkFunctionDeclarations": true, - "checkFunctionExpressions": true, - "checkMethodDeclarations": true, - }, - ], - "meta": { - "docs": { - "description": "Require any function or method that returns a Promise to be marked async", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/promise-function-async", - }, - "fixable": "code", - "messages": { - "missingAsync": "Functions that return promises must be async.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAny": { - "description": "Whether to consider \`any\` and \`unknown\` to be Promises.", - "type": "boolean", - }, - "allowedPromiseNames": { - "description": "Any extra names of classes or interfaces to be considered Promises.", - "items": { - "type": "string", - }, - "type": "array", - }, - "checkArrowFunctions": { - "type": "boolean", - }, - "checkFunctionDeclarations": { - "type": "boolean", - }, - "checkFunctionExpressions": { - "type": "boolean", - }, - "checkMethodDeclarations": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "quotes": { - "create": [Function], - "defaultOptions": [ - "double", - { - "allowTemplateLiterals": false, - "avoidEscape": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce the consistent use of either backticks, double, or single quotes", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/quotes", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "wrongQuotes": "Strings must use {{description}}.", - }, - "replacedBy": [ - "@stylistic/ts/quotes", - ], - "schema": [ - { - "enum": [ - "single", - "double", - "backtick", - ], - }, - { - "anyOf": [ - { - "enum": [ - "avoid-escape", - ], - }, - { - "additionalProperties": false, - "properties": { - "allowTemplateLiterals": { - "type": "boolean", - }, - "avoidEscape": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "layout", - }, - }, - "require-array-sort-compare": { - "create": [Function], - "defaultOptions": [ - { - "ignoreStringArrays": true, - }, - ], - "meta": { - "docs": { - "description": "Require \`Array#sort\` and \`Array#toSorted\` calls to always provide a \`compareFunction\`", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/require-array-sort-compare", - }, - "messages": { - "requireCompare": "Require 'compare' argument.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreStringArrays": { - "description": "Whether to ignore arrays in which all elements are strings.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "require-await": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Disallow async functions which have no \`await\` expression", - "extendsBaseRule": true, - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/require-await", - }, - "messages": { - "missingAwait": "{{name}} has no 'await' expression.", - }, - "schema": [], - "type": "suggestion", - }, - }, - "restrict-plus-operands": { - "create": [Function], - "defaultOptions": [ - { - "allowAny": true, - "allowBoolean": true, - "allowNullish": true, - "allowNumberAndString": true, - "allowRegExp": true, - "skipCompoundAssignments": false, - }, - ], - "meta": { - "docs": { - "description": "Require both operands of addition to be the same type and be \`bigint\`, \`number\`, or \`string\`", - "recommended": { - "recommended": true, - "strict": [ - { - "allowAny": false, - "allowBoolean": false, - "allowNullish": false, - "allowNumberAndString": false, - "allowRegExp": false, - }, - ], - }, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/restrict-plus-operands", - }, - "messages": { - "bigintAndNumber": "Numeric '+' operations must either be both bigints or both numbers. Got \`{{left}}\` + \`{{right}}\`.", - "invalid": "Invalid operand for a '+' operation. Operands must each be a number or {{stringLike}}. Got \`{{type}}\`.", - "mismatched": "Operands of '+' operations must be a number or {{stringLike}}. Got \`{{left}}\` + \`{{right}}\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAny": { - "description": "Whether to allow \`any\` typed values.", - "type": "boolean", - }, - "allowBoolean": { - "description": "Whether to allow \`boolean\` typed values.", - "type": "boolean", - }, - "allowNullish": { - "description": "Whether to allow potentially \`null\` or \`undefined\` typed values.", - "type": "boolean", - }, - "allowNumberAndString": { - "description": "Whether to allow \`bigint\`/\`number\` typed values and \`string\` typed values to be added together.", - "type": "boolean", - }, - "allowRegExp": { - "description": "Whether to allow \`regexp\` typed values.", - "type": "boolean", - }, - "skipCompoundAssignments": { - "description": "Whether to skip compound assignments such as \`+=\`.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "restrict-template-expressions": { - "create": [Function], - "defaultOptions": [ - { - "allowAny": true, - "allowBoolean": true, - "allowNullish": true, - "allowNumber": true, - "allowRegExp": true, - }, - ], - "meta": { - "docs": { - "description": "Enforce template literal expressions to be of \`string\` type", - "recommended": { - "recommended": true, - "strict": [ - { - "allowAny": false, - "allowBoolean": false, - "allowNever": false, - "allowNullish": false, - "allowNumber": false, - "allowRegExp": false, - }, - ], - }, - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/restrict-template-expressions", - }, - "messages": { - "invalidType": "Invalid type "{{type}}" of template literal expression.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAny": { - "description": "Whether to allow \`any\` typed values in template expressions.", - "type": "boolean", - }, - "allowArray": { - "description": "Whether to allow \`array\` typed values in template expressions.", - "type": "boolean", - }, - "allowBoolean": { - "description": "Whether to allow \`boolean\` typed values in template expressions.", - "type": "boolean", - }, - "allowNever": { - "description": "Whether to allow \`never\` typed values in template expressions.", - "type": "boolean", - }, - "allowNullish": { - "description": "Whether to allow \`nullish\` typed values in template expressions.", - "type": "boolean", - }, - "allowNumber": { - "description": "Whether to allow \`number\` typed values in template expressions.", - "type": "boolean", - }, - "allowRegExp": { - "description": "Whether to allow \`regexp\` typed values in template expressions.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "return-await": { - "create": [Function], - "defaultOptions": [ - "in-try-catch", - ], - "meta": { - "docs": { - "description": "Enforce consistent returning of awaited values", - "extendsBaseRule": "no-return-await", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/return-await", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "disallowedPromiseAwait": "Returning an awaited promise is not allowed in this context.", - "nonPromiseAwait": "Returning an awaited value that is not a promise is not allowed.", - "requiredPromiseAwait": "Returning an awaited promise is required in this context.", - }, - "schema": [ - { - "enum": [ - "in-try-catch", - "always", - "never", - ], - "type": "string", - }, - ], - "type": "problem", - }, - }, - "semi": { - "create": [Function], - "defaultOptions": [ - "always", - { - "beforeStatementContinuationChars": "any", - "omitLastInOneLineBlock": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require or disallow semicolons instead of ASI", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/semi", - }, - "fixable": "code", - "hasSuggestions": undefined, - "messages": { - "extraSemi": "Extra semicolon.", - "missingSemi": "Missing semicolon.", - }, - "replacedBy": [ - "@stylistic/ts/semi", - ], - "schema": { - "anyOf": [ - { - "items": [ - { - "enum": [ - "never", - ], - }, - { - "additionalProperties": false, - "properties": { - "beforeStatementContinuationChars": { - "enum": [ - "always", - "any", - "never", - ], - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - { - "items": [ - { - "enum": [ - "always", - ], - }, - { - "additionalProperties": false, - "properties": { - "omitLastInOneLineBlock": { - "type": "boolean", - }, - "omitLastInOneLineClassBody": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "maxItems": 2, - "minItems": 0, - "type": "array", - }, - ], - }, - "type": "layout", - }, - }, - "sort-type-constituents": { - "create": [Function], - "defaultOptions": [ - { - "checkIntersections": true, - "checkUnions": true, - "groupOrder": [ - "named", - "keyword", - "operator", - "literal", - "function", - "import", - "conditional", - "object", - "tuple", - "intersection", - "union", - "nullish", - ], - }, - ], - "meta": { - "docs": { - "description": "Enforce constituents of a type union/intersection to be sorted alphabetically", - "url": "https://typescript-eslint.io/rules/sort-type-constituents", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "notSorted": "{{type}} type constituents must be sorted.", - "notSortedNamed": "{{type}} type {{name}} constituents must be sorted.", - "suggestFix": "Sort constituents of type (removes all comments).", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "checkIntersections": { - "description": "Whether to check intersection types.", - "type": "boolean", - }, - "checkUnions": { - "description": "Whether to check union types.", - "type": "boolean", - }, - "groupOrder": { - "description": "Ordering of the groups.", - "items": { - "enum": [ - "conditional", - "function", - "import", - "intersection", - "keyword", - "nullish", - "literal", - "named", - "object", - "operator", - "tuple", - "union", - ], - "type": "string", - }, - "type": "array", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "space-before-blocks": { - "create": [Function], - "defaultOptions": [ - "always", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing before blocks", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/space-before-blocks", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "missingSpace": "Missing space before opening brace.", - "unexpectedSpace": "Unexpected space before opening brace.", - }, - "replacedBy": [ - "@stylistic/ts/space-before-blocks", - ], - "schema": [ - { - "oneOf": [ - { - "enum": [ - "always", - "never", - ], - }, - { - "additionalProperties": false, - "properties": { - "classes": { - "enum": [ - "always", - "never", - "off", - ], - }, - "functions": { - "enum": [ - "always", - "never", - "off", - ], - }, - "keywords": { - "enum": [ - "always", - "never", - "off", - ], - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "layout", - }, - }, - "space-before-function-paren": { - "create": [Function], - "defaultOptions": [ - "always", - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Enforce consistent spacing before function parenthesis", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/space-before-function-paren", - }, - "fixable": "whitespace", - "messages": { - "missing": "Missing space before function parentheses.", - "unexpected": "Unexpected space before function parentheses.", - }, - "replacedBy": [ - "@stylistic/ts/space-before-function-paren", - ], - "schema": [ - { - "oneOf": [ - { - "enum": [ - "always", - "never", - ], - "type": "string", - }, - { - "additionalProperties": false, - "properties": { - "anonymous": { - "enum": [ - "always", - "never", - "ignore", - ], - "type": "string", - }, - "asyncArrow": { - "enum": [ - "always", - "never", - "ignore", - ], - "type": "string", - }, - "named": { - "enum": [ - "always", - "never", - "ignore", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - }, - ], - "type": "layout", - }, - }, - "space-infix-ops": { - "create": [Function], - "defaultOptions": [ - { - "int32Hint": false, - }, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require spacing around infix operators", - "extendsBaseRule": true, - "url": "https://typescript-eslint.io/rules/space-infix-ops", - }, - "fixable": "whitespace", - "hasSuggestions": undefined, - "messages": { - "missingSpace": "Operator '{{operator}}' must be spaced.", - }, - "replacedBy": [ - "@stylistic/ts/space-infix-ops", - ], - "schema": [ - { - "additionalProperties": false, - "properties": { - "int32Hint": { - "default": false, - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "strict-boolean-expressions": { - "create": [Function], - "defaultOptions": [ - { - "allowAny": false, - "allowNullableBoolean": false, - "allowNullableEnum": false, - "allowNullableNumber": false, - "allowNullableObject": true, - "allowNullableString": false, - "allowNumber": true, - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, - "allowString": true, - }, - ], - "meta": { - "docs": { - "description": "Disallow certain types in boolean expressions", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/strict-boolean-expressions", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "conditionErrorAny": "Unexpected any value in conditional. An explicit comparison or type cast is required.", - "conditionErrorNullableBoolean": "Unexpected nullable boolean value in conditional. Please handle the nullish case explicitly.", - "conditionErrorNullableEnum": "Unexpected nullable enum value in conditional. Please handle the nullish/zero/NaN cases explicitly.", - "conditionErrorNullableNumber": "Unexpected nullable number value in conditional. Please handle the nullish/zero/NaN cases explicitly.", - "conditionErrorNullableObject": "Unexpected nullable object value in conditional. An explicit null check is required.", - "conditionErrorNullableString": "Unexpected nullable string value in conditional. Please handle the nullish/empty cases explicitly.", - "conditionErrorNullish": "Unexpected nullish value in conditional. The condition is always false.", - "conditionErrorNumber": "Unexpected number value in conditional. An explicit zero/NaN check is required.", - "conditionErrorObject": "Unexpected object value in conditional. The condition is always true.", - "conditionErrorOther": "Unexpected value in conditional. A boolean expression is required.", - "conditionErrorString": "Unexpected string value in conditional. An explicit empty string check is required.", - "conditionFixCastBoolean": "Explicitly cast value to a boolean (\`Boolean(value)\`)", - "conditionFixCompareEmptyString": "Change condition to check for empty string (\`value !== ""\`)", - "conditionFixCompareFalse": "Change condition to check if false (\`value === false\`)", - "conditionFixCompareNaN": "Change condition to check for NaN (\`!Number.isNaN(value)\`)", - "conditionFixCompareNullish": "Change condition to check for null/undefined (\`value != null\`)", - "conditionFixCompareStringLength": "Change condition to check string's length (\`value.length !== 0\`)", - "conditionFixCompareTrue": "Change condition to check if true (\`value === true\`)", - "conditionFixCompareZero": "Change condition to check for 0 (\`value !== 0\`)", - "conditionFixDefaultEmptyString": "Explicitly treat nullish value the same as an empty string (\`value ?? ""\`)", - "conditionFixDefaultFalse": "Explicitly treat nullish value the same as false (\`value ?? false\`)", - "conditionFixDefaultZero": "Explicitly treat nullish value the same as 0 (\`value ?? 0\`)", - "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowAny": { - "type": "boolean", - }, - "allowNullableBoolean": { - "type": "boolean", - }, - "allowNullableEnum": { - "type": "boolean", - }, - "allowNullableNumber": { - "type": "boolean", - }, - "allowNullableObject": { - "type": "boolean", - }, - "allowNullableString": { - "type": "boolean", - }, - "allowNumber": { - "type": "boolean", - }, - "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { - "type": "boolean", - }, - "allowString": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "switch-exhaustiveness-check": { - "create": [Function], - "defaultOptions": [ - { - "allowDefaultCaseForExhaustiveSwitch": true, - "requireDefaultForNonUnion": false, - }, - ], - "meta": { - "docs": { - "description": "Require switch-case statements to be exhaustive", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/switch-exhaustiveness-check", - }, - "hasSuggestions": true, - "messages": { - "addMissingCases": "Add branches for missing cases.", - "dangerousDefaultCase": "The switch statement is exhaustive, so the default case is unnecessary.", - "switchIsNotExhaustive": "Switch is not exhaustive. Cases not matched: {{missingBranches}}", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "allowDefaultCaseForExhaustiveSwitch": { - "description": "If 'true', allow 'default' cases on switch statements with exhaustive cases.", - "type": "boolean", - }, - "requireDefaultForNonUnion": { - "description": "If 'true', require a 'default' clause for switches on non-union types.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "triple-slash-reference": { - "create": [Function], - "defaultOptions": [ - { - "lib": "always", - "path": "never", - "types": "prefer-import", - }, - ], - "meta": { - "docs": { - "description": "Disallow certain triple slash directives in favor of ES6-style import declarations", - "recommended": "recommended", - "url": "https://typescript-eslint.io/rules/triple-slash-reference", - }, - "messages": { - "tripleSlashReference": "Do not use a triple slash reference for {{module}}, use \`import\` style instead.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "lib": { - "enum": [ - "always", - "never", - ], - "type": "string", - }, - "path": { - "enum": [ - "always", - "never", - ], - "type": "string", - }, - "types": { - "enum": [ - "always", - "never", - "prefer-import", - ], - "type": "string", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "type-annotation-spacing": { - "create": [Function], - "defaultOptions": [ - {}, - ], - "meta": { - "deprecated": true, - "docs": { - "description": "Require consistent spacing around type annotations", - "url": "https://typescript-eslint.io/rules/type-annotation-spacing", - }, - "fixable": "whitespace", - "messages": { - "expectedSpaceAfter": "Expected a space after the '{{type}}'.", - "expectedSpaceBefore": "Expected a space before the '{{type}}'.", - "unexpectedSpaceAfter": "Unexpected space after the '{{type}}'.", - "unexpectedSpaceBefore": "Unexpected space before the '{{type}}'.", - "unexpectedSpaceBetween": "Unexpected space between the '{{previousToken}}' and the '{{type}}'.", - }, - "replacedBy": [ - "@stylistic/ts/type-annotation-spacing", - ], - "schema": [ - { - "$defs": { - "spacingConfig": { - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - }, - "type": "object", - }, - }, - "additionalProperties": false, - "properties": { - "after": { - "type": "boolean", - }, - "before": { - "type": "boolean", - }, - "overrides": { - "additionalProperties": false, - "properties": { - "arrow": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "colon": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "parameter": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "property": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "returnType": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - "variable": { - "$ref": "#/items/0/$defs/spacingConfig", - }, - }, - "type": "object", - }, - }, - "type": "object", - }, - ], - "type": "layout", - }, - }, - "typedef": { - "create": [Function], - "defaultOptions": [ - { - "arrayDestructuring": false, - "arrowParameter": false, - "memberVariableDeclaration": false, - "objectDestructuring": false, - "parameter": false, - "propertyDeclaration": false, - "variableDeclaration": false, - "variableDeclarationIgnoreFunction": false, - }, - ], - "meta": { - "docs": { - "description": "Require type annotations in certain places", - "url": "https://typescript-eslint.io/rules/typedef", - }, - "messages": { - "expectedTypedef": "Expected a type annotation.", - "expectedTypedefNamed": "Expected {{name}} to have a type annotation.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "arrayDestructuring": { - "type": "boolean", - }, - "arrowParameter": { - "type": "boolean", - }, - "memberVariableDeclaration": { - "type": "boolean", - }, - "objectDestructuring": { - "type": "boolean", - }, - "parameter": { - "type": "boolean", - }, - "propertyDeclaration": { - "type": "boolean", - }, - "variableDeclaration": { - "type": "boolean", - }, - "variableDeclarationIgnoreFunction": { - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "unbound-method": { - "create": [Function], - "defaultOptions": [ - { - "ignoreStatic": false, - }, - ], - "meta": { - "docs": { - "description": "Enforce unbound methods are called with their expected scope", - "recommended": "recommended", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/unbound-method", - }, - "messages": { - "unbound": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`.", - "unboundWithoutThisAnnotation": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`. -If your function does not access \`this\`, you can annotate it with \`this: void\`, or consider using an arrow function instead.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreStatic": { - "description": "Whether to skip checking whether \`static\` methods are correctly bound.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "problem", - }, - }, - "unified-signatures": { - "create": [Function], - "defaultOptions": [ - { - "ignoreDifferentlyNamedParameters": false, - }, - ], - "meta": { - "docs": { - "description": "Disallow two overloads that could be unified into one with a union or an optional/rest parameter", - "recommended": "strict", - "url": "https://typescript-eslint.io/rules/unified-signatures", - }, - "messages": { - "omittingRestParameter": "{{failureStringStart}} with a rest parameter.", - "omittingSingleParameter": "{{failureStringStart}} with an optional parameter.", - "singleParameterDifference": "{{failureStringStart}} taking \`{{type1}} | {{type2}}\`.", - }, - "schema": [ - { - "additionalProperties": false, - "properties": { - "ignoreDifferentlyNamedParameters": { - "description": "Whether two parameters with different names at the same index should be considered different even if their types are the same.", - "type": "boolean", - }, - }, - "type": "object", - }, - ], - "type": "suggestion", - }, - }, - "use-unknown-in-catch-callback-variable": { - "create": [Function], - "defaultOptions": [], - "meta": { - "docs": { - "description": "Enforce typing arguments in \`.catch()\` callbacks as \`unknown\`", - "recommended": "strict", - "requiresTypeChecking": true, - "url": "https://typescript-eslint.io/rules/use-unknown-in-catch-callback-variable", - }, - "fixable": "code", - "hasSuggestions": true, - "messages": { - "addUnknownRestTypeAnnotationSuggestion": "Add an explicit \`: [unknown]\` type annotation to the catch rest variable.", - "addUnknownTypeAnnotationSuggestion": "Add an explicit \`: unknown\` type annotation to the catch variable.", - "useUnknown": "Prefer the safe \`: unknown\` for a catch callback variable.", - "useUnknownArrayDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may not be iterable.", - "useUnknownObjectDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may be nullable, or may not have the expected shape.", - "useUnknownSpreadArgs": "Prefer the safe \`: unknown\` for a catch callback variable. The argument list may contain a handler that does not use \`unknown\` for the catch callback variable.", - "wrongRestTypeAnnotationSuggestion": "Change existing type annotation to \`: [unknown]\`.", - "wrongTypeAnnotationSuggestion": "Change existing type annotation to \`: unknown\`.", - }, - "schema": [], - "type": "suggestion", - }, - }, - }, - }, - }, - }, - { - "files": [ - "**/*.ts", - "**/*.tsx", - "**/*.mts", - "**/*.cts", - ], - "name": "jimmy.codes/typescript", - "rules": { - "constructor-super": "off", - "getter-return": "off", - "no-const-assign": "off", - "no-dupe-args": "off", - "no-dupe-class-members": "off", - "no-dupe-keys": "off", - "no-func-assign": "off", - "no-import-assign": "off", - "no-new-symbol": "off", - "no-obj-calls": "off", - "no-redeclare": "off", - "no-setter-return": "off", - "no-this-before-super": "off", - "no-undef": "off", - "no-unreachable": "off", - "no-unsafe-negation": "off", - "no-var": "error", - "prefer-const": "error", - "prefer-rest-params": "error", - "prefer-spread": "error", - }, - }, - { - "name": "jimmy.codes/typescript", - "rules": { - "@typescript-eslint/adjacent-overload-signatures": "error", - "@typescript-eslint/array-type": "error", - "@typescript-eslint/ban-tslint-comment": "error", - "@typescript-eslint/class-literal-property-style": "error", - "@typescript-eslint/consistent-generic-constructors": "error", - "@typescript-eslint/consistent-indexed-object-style": "error", - "@typescript-eslint/consistent-type-assertions": "error", - "@typescript-eslint/consistent-type-definitions": "error", - "@typescript-eslint/dot-notation": "error", - "@typescript-eslint/no-confusing-non-null-assertion": "error", - "@typescript-eslint/no-empty-function": "error", - "@typescript-eslint/no-empty-interface": "error", - "@typescript-eslint/no-inferrable-types": "error", - "@typescript-eslint/non-nullable-type-assertion-style": "error", - "@typescript-eslint/prefer-for-of": "error", - "@typescript-eslint/prefer-function-type": "error", - "@typescript-eslint/prefer-namespace-keyword": "error", - "@typescript-eslint/prefer-nullish-coalescing": "error", - "@typescript-eslint/prefer-optional-chain": "error", - "@typescript-eslint/prefer-string-starts-ends-with": "error", - "dot-notation": "off", - "no-empty-function": "off", - }, - }, - { - "name": "jimmy.codes/typescript", - "rules": { - "@typescript-eslint/consistent-type-exports": [ - "error", - { - "fixMixedExportsWithInlineTypeSpecifier": true, - }, - ], - "@typescript-eslint/consistent-type-imports": [ - "error", - { - "fixStyle": "inline-type-imports", - }, - ], - "@typescript-eslint/no-misused-promises": [ - "error", - { - "checksVoidReturn": { - "attributes": false, - }, - }, - ], - }, - }, - { - "languageOptions": { - "parserOptions": { - "project": "./tsconfig.json", - "tsconfigRootDir": "/", - }, - }, - "name": "jimmy.codes/typescript", - }, - { - "files": [ - "**/*.?([cm])js", - "**/*.?([cm])jsx", - ], - "languageOptions": { - "parserOptions": { - "program": null, - "project": false, - }, - }, - "name": "jimmy.codes/typescript", - "rules": { - "@typescript-eslint/await-thenable": "off", - "@typescript-eslint/consistent-return": "off", - "@typescript-eslint/consistent-type-exports": "off", - "@typescript-eslint/dot-notation": "off", - "@typescript-eslint/naming-convention": "off", - "@typescript-eslint/no-array-delete": "off", - "@typescript-eslint/no-base-to-string": "off", - "@typescript-eslint/no-confusing-void-expression": "off", - "@typescript-eslint/no-duplicate-type-constituents": "off", - "@typescript-eslint/no-floating-promises": "off", - "@typescript-eslint/no-for-in-array": "off", - "@typescript-eslint/no-implied-eval": "off", - "@typescript-eslint/no-meaningless-void-operator": "off", - "@typescript-eslint/no-misused-promises": "off", - "@typescript-eslint/no-mixed-enums": "off", - "@typescript-eslint/no-redundant-type-constituents": "off", - "@typescript-eslint/no-throw-literal": "off", - "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off", - "@typescript-eslint/no-unnecessary-condition": "off", - "@typescript-eslint/no-unnecessary-qualifier": "off", - "@typescript-eslint/no-unnecessary-type-arguments": "off", - "@typescript-eslint/no-unnecessary-type-assertion": "off", - "@typescript-eslint/no-unsafe-argument": "off", - "@typescript-eslint/no-unsafe-assignment": "off", - "@typescript-eslint/no-unsafe-call": "off", - "@typescript-eslint/no-unsafe-enum-comparison": "off", - "@typescript-eslint/no-unsafe-member-access": "off", - "@typescript-eslint/no-unsafe-return": "off", - "@typescript-eslint/no-unsafe-unary-minus": "off", - "@typescript-eslint/no-useless-template-literals": "off", - "@typescript-eslint/non-nullable-type-assertion-style": "off", - "@typescript-eslint/only-throw-error": "off", - "@typescript-eslint/prefer-destructuring": "off", - "@typescript-eslint/prefer-find": "off", - "@typescript-eslint/prefer-includes": "off", - "@typescript-eslint/prefer-nullish-coalescing": "off", - "@typescript-eslint/prefer-optional-chain": "off", - "@typescript-eslint/prefer-promise-reject-errors": "off", - "@typescript-eslint/prefer-readonly": "off", - "@typescript-eslint/prefer-readonly-parameter-types": "off", - "@typescript-eslint/prefer-reduce-type-parameter": "off", - "@typescript-eslint/prefer-regexp-exec": "off", - "@typescript-eslint/prefer-return-this-type": "off", - "@typescript-eslint/prefer-string-starts-ends-with": "off", - "@typescript-eslint/promise-function-async": "off", - "@typescript-eslint/require-array-sort-compare": "off", - "@typescript-eslint/require-await": "off", - "@typescript-eslint/restrict-plus-operands": "off", - "@typescript-eslint/restrict-template-expressions": "off", - "@typescript-eslint/return-await": "off", - "@typescript-eslint/strict-boolean-expressions": "off", - "@typescript-eslint/switch-exhaustiveness-check": "off", - "@typescript-eslint/unbound-method": "off", - "@typescript-eslint/use-unknown-in-catch-callback-variable": "off", - }, - }, - { - "name": "jimmy.codes/disabled", - "rules": { - "@babel/object-curly-spacing": "off", - "@babel/semi": "off", - "@typescript-eslint/block-spacing": "off", - "@typescript-eslint/brace-style": "off", - "@typescript-eslint/comma-dangle": "off", - "@typescript-eslint/comma-spacing": "off", - "@typescript-eslint/func-call-spacing": "off", - "@typescript-eslint/indent": "off", - "@typescript-eslint/key-spacing": "off", - "@typescript-eslint/keyword-spacing": "off", - "@typescript-eslint/lines-around-comment": 0, - "@typescript-eslint/member-delimiter-style": "off", - "@typescript-eslint/no-extra-parens": "off", - "@typescript-eslint/no-extra-semi": "off", - "@typescript-eslint/object-curly-spacing": "off", - "@typescript-eslint/quotes": 0, - "@typescript-eslint/semi": "off", - "@typescript-eslint/space-before-blocks": "off", - "@typescript-eslint/space-before-function-paren": "off", - "@typescript-eslint/space-infix-ops": "off", - "@typescript-eslint/type-annotation-spacing": "off", - "array-bracket-newline": "off", - "array-bracket-spacing": "off", - "array-element-newline": "off", - "arrow-parens": "off", - "arrow-spacing": "off", - "babel/object-curly-spacing": "off", - "babel/quotes": 0, - "babel/semi": "off", - "block-spacing": "off", - "brace-style": "off", - "comma-dangle": "off", - "comma-spacing": "off", - "comma-style": "off", - "computed-property-spacing": "off", - "curly": 0, - "dot-location": "off", - "eol-last": "off", - "flowtype/boolean-style": "off", - "flowtype/delimiter-dangle": "off", - "flowtype/generic-spacing": "off", - "flowtype/object-type-curly-spacing": "off", - "flowtype/object-type-delimiter": "off", - "flowtype/quotes": "off", - "flowtype/semi": "off", - "flowtype/space-after-type-colon": "off", - "flowtype/space-before-generic-bracket": "off", - "flowtype/space-before-type-colon": "off", - "flowtype/union-intersection-spacing": "off", - "func-call-spacing": "off", - "function-call-argument-newline": "off", - "function-paren-newline": "off", - "generator-star": "off", - "generator-star-spacing": "off", - "implicit-arrow-linebreak": "off", - "indent": "off", - "indent-legacy": "off", - "jsx-quotes": "off", - "key-spacing": "off", - "keyword-spacing": "off", - "linebreak-style": "off", - "lines-around-comment": 0, - "max-len": 0, - "max-statements-per-line": "off", - "multiline-ternary": "off", - "new-parens": "off", - "newline-per-chained-call": "off", - "no-arrow-condition": "off", - "no-comma-dangle": "off", - "no-confusing-arrow": 0, - "no-extra-parens": "off", - "no-extra-semi": "off", - "no-floating-decimal": "off", - "no-mixed-operators": 0, - "no-mixed-spaces-and-tabs": "off", - "no-multi-spaces": "off", - "no-multiple-empty-lines": "off", - "no-reserved-keys": "off", - "no-space-before-semi": "off", - "no-spaced-func": "off", - "no-tabs": 0, - "no-trailing-spaces": "off", - "no-unexpected-multiline": 0, - "no-whitespace-before-property": "off", - "no-wrap-func": "off", - "nonblock-statement-body-position": "off", - "object-curly-newline": "off", - "object-curly-spacing": "off", - "object-property-newline": "off", - "one-var-declaration-per-line": "off", - "operator-linebreak": "off", - "padded-blocks": "off", - "quote-props": "off", - "quotes": 0, - "react/jsx-child-element-spacing": "off", - "react/jsx-closing-bracket-location": "off", - "react/jsx-closing-tag-location": "off", - "react/jsx-curly-newline": "off", - "react/jsx-curly-spacing": "off", - "react/jsx-equals-spacing": "off", - "react/jsx-first-prop-new-line": "off", - "react/jsx-indent": "off", - "react/jsx-indent-props": "off", - "react/jsx-max-props-per-line": "off", - "react/jsx-newline": "off", - "react/jsx-one-expression-per-line": "off", - "react/jsx-props-no-multi-spaces": "off", - "react/jsx-space-before-closing": "off", - "react/jsx-tag-spacing": "off", - "react/jsx-wrap-multilines": "off", - "rest-spread-spacing": "off", - "semi": "off", - "semi-spacing": "off", - "semi-style": "off", - "space-after-function-name": "off", - "space-after-keywords": "off", - "space-before-blocks": "off", - "space-before-function-paren": "off", - "space-before-function-parentheses": "off", - "space-before-keywords": "off", - "space-in-brackets": "off", - "space-in-parens": "off", - "space-infix-ops": "off", - "space-return-throw-case": "off", - "space-unary-ops": "off", - "space-unary-word-ops": "off", - "standard/array-bracket-even-spacing": "off", - "standard/computed-property-even-spacing": "off", - "standard/object-curly-even-spacing": "off", - "switch-colon-spacing": "off", - "template-curly-spacing": "off", - "template-tag-spacing": "off", - "unicorn/empty-brace-spaces": "off", - "unicorn/no-nested-ternary": "off", - "unicorn/number-literal-case": "off", - "unicorn/template-indent": 0, - "vue/array-bracket-newline": "off", - "vue/array-bracket-spacing": "off", - "vue/array-element-newline": "off", - "vue/arrow-spacing": "off", - "vue/block-spacing": "off", - "vue/block-tag-newline": "off", - "vue/brace-style": "off", - "vue/comma-dangle": "off", - "vue/comma-spacing": "off", - "vue/comma-style": "off", - "vue/dot-location": "off", - "vue/func-call-spacing": "off", - "vue/html-closing-bracket-newline": "off", - "vue/html-closing-bracket-spacing": "off", - "vue/html-end-tags": "off", - "vue/html-indent": "off", - "vue/html-quotes": "off", - "vue/html-self-closing": 0, - "vue/key-spacing": "off", - "vue/keyword-spacing": "off", - "vue/max-attributes-per-line": "off", - "vue/max-len": 0, - "vue/multiline-html-element-content-newline": "off", - "vue/multiline-ternary": "off", - "vue/mustache-interpolation-spacing": "off", - "vue/no-extra-parens": "off", - "vue/no-multi-spaces": "off", - "vue/no-spaces-around-equal-signs-in-attribute": "off", - "vue/object-curly-newline": "off", - "vue/object-curly-spacing": "off", - "vue/object-property-newline": "off", - "vue/operator-linebreak": "off", - "vue/quote-props": "off", - "vue/script-indent": "off", - "vue/singleline-html-element-content-newline": "off", - "vue/space-in-parens": "off", - "vue/space-infix-ops": "off", - "vue/space-unary-ops": "off", - "vue/template-curly-spacing": "off", - "wrap-iife": "off", - "wrap-regex": "off", - "yield-star-spacing": "off", - }, - }, - { - "ignores": [ - "**/node_modules", - "**/dist", - "**/package-lock.json", - "**/yarn.lock", - "**/pnpm-lock.yaml", - "**/bun.lockb", - "**/output", - "**/coverage", - "**/temp", - "**/.temp", - "**/tmp", - "**/.tmp", - "**/.history", - "**/.vitepress/cache", - "**/.nuxt", - "**/.next", - "**/.vercel", - "**/.changeset", - "**/.idea", - "**/.cache", - "**/.output", - "**/.vite-inspect", - "**/.yarn", - "**/storybook-static", - "**/.eslint-config-inspector", - "**/CHANGELOG*.md", - "**/*.min.*", - "**/LICENSE*", - "**/__snapshots__", - "**/auto-import?(s).d.ts", - "**/components.d.ts", - "**/vite.config.ts.*.mjs", - ], - }, -] -`; - exports[`jimmyDotCodes > should create configuration w/ vitest & react & testing library 1`] = ` [ { diff --git a/src/configs/__snapshots__/typescript.spec.ts.snap b/src/configs/__snapshots__/typescript.spec.ts.snap new file mode 100644 index 0000000..0f668d4 --- /dev/null +++ b/src/configs/__snapshots__/typescript.spec.ts.snap @@ -0,0 +1,31789 @@ +// Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html + +exports[`typescriptConfig > should create config 1`] = ` +[ + { + "languageOptions": { + "parser": { + "meta": { + "name": "typescript-eslint/parser", + "version": "7.6.0", + }, + "parseForESLint": [Function], + }, + "sourceType": "module", + }, + "name": "typescript-eslint/base", + "plugins": { + "@typescript-eslint": { + "configs": { + "all": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/class-methods-use-this": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-return": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/consistent-type-exports": "error", + "@typescript-eslint/consistent-type-imports": "error", + "@typescript-eslint/default-param-last": "error", + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/explicit-function-return-type": "error", + "@typescript-eslint/explicit-member-accessibility": "error", + "@typescript-eslint/explicit-module-boundary-types": "error", + "@typescript-eslint/init-declarations": "error", + "@typescript-eslint/max-params": "error", + "@typescript-eslint/member-ordering": "error", + "@typescript-eslint/method-signature-style": "error", + "@typescript-eslint/naming-convention": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-dupe-class-members": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-import-type-side-effects": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/no-invalid-this": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loop-func": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-magic-numbers": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-redeclare": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-require-imports": "error", + "@typescript-eslint/no-restricted-imports": "error", + "@typescript-eslint/no-shadow": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-qualifier": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unsafe-unary-minus": "error", + "@typescript-eslint/no-unused-expressions": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-use-before-define": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-useless-empty-export": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/parameter-properties": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-destructuring": "error", + "@typescript-eslint/prefer-enum-initializers": "error", + "@typescript-eslint/prefer-find": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-readonly": "error", + "@typescript-eslint/prefer-readonly-parameter-types": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-regexp-exec": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/promise-function-async": "error", + "@typescript-eslint/require-array-sort-compare": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/return-await": "error", + "@typescript-eslint/sort-type-constituents": "error", + "@typescript-eslint/strict-boolean-expressions": "error", + "@typescript-eslint/switch-exhaustiveness-check": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/typedef": "error", + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/unified-signatures": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "class-methods-use-this": "off", + "consistent-return": "off", + "default-param-last": "off", + "dot-notation": "off", + "init-declarations": "off", + "max-params": "off", + "no-array-constructor": "off", + "no-dupe-class-members": "off", + "no-empty-function": "off", + "no-implied-eval": "off", + "no-invalid-this": "off", + "no-loop-func": "off", + "no-loss-of-precision": "off", + "no-magic-numbers": "off", + "no-redeclare": "off", + "no-restricted-imports": "off", + "no-return-await": "off", + "no-shadow": "off", + "no-throw-literal": "off", + "no-unused-expressions": "off", + "no-unused-vars": "off", + "no-use-before-define": "off", + "no-useless-constructor": "off", + "prefer-destructuring": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "base": { + "parser": "@typescript-eslint/parser", + "parserOptions": { + "sourceType": "module", + }, + "plugins": [ + "@typescript-eslint", + ], + }, + "disable-type-checked": { + "parserOptions": { + "program": null, + "project": false, + }, + "rules": { + "@typescript-eslint/await-thenable": "off", + "@typescript-eslint/consistent-return": "off", + "@typescript-eslint/consistent-type-exports": "off", + "@typescript-eslint/dot-notation": "off", + "@typescript-eslint/naming-convention": "off", + "@typescript-eslint/no-array-delete": "off", + "@typescript-eslint/no-base-to-string": "off", + "@typescript-eslint/no-confusing-void-expression": "off", + "@typescript-eslint/no-duplicate-type-constituents": "off", + "@typescript-eslint/no-floating-promises": "off", + "@typescript-eslint/no-for-in-array": "off", + "@typescript-eslint/no-implied-eval": "off", + "@typescript-eslint/no-meaningless-void-operator": "off", + "@typescript-eslint/no-misused-promises": "off", + "@typescript-eslint/no-mixed-enums": "off", + "@typescript-eslint/no-redundant-type-constituents": "off", + "@typescript-eslint/no-throw-literal": "off", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off", + "@typescript-eslint/no-unnecessary-condition": "off", + "@typescript-eslint/no-unnecessary-qualifier": "off", + "@typescript-eslint/no-unnecessary-type-arguments": "off", + "@typescript-eslint/no-unnecessary-type-assertion": "off", + "@typescript-eslint/no-unsafe-argument": "off", + "@typescript-eslint/no-unsafe-assignment": "off", + "@typescript-eslint/no-unsafe-call": "off", + "@typescript-eslint/no-unsafe-enum-comparison": "off", + "@typescript-eslint/no-unsafe-member-access": "off", + "@typescript-eslint/no-unsafe-return": "off", + "@typescript-eslint/no-unsafe-unary-minus": "off", + "@typescript-eslint/no-useless-template-literals": "off", + "@typescript-eslint/non-nullable-type-assertion-style": "off", + "@typescript-eslint/only-throw-error": "off", + "@typescript-eslint/prefer-destructuring": "off", + "@typescript-eslint/prefer-find": "off", + "@typescript-eslint/prefer-includes": "off", + "@typescript-eslint/prefer-nullish-coalescing": "off", + "@typescript-eslint/prefer-optional-chain": "off", + "@typescript-eslint/prefer-promise-reject-errors": "off", + "@typescript-eslint/prefer-readonly": "off", + "@typescript-eslint/prefer-readonly-parameter-types": "off", + "@typescript-eslint/prefer-reduce-type-parameter": "off", + "@typescript-eslint/prefer-regexp-exec": "off", + "@typescript-eslint/prefer-return-this-type": "off", + "@typescript-eslint/prefer-string-starts-ends-with": "off", + "@typescript-eslint/promise-function-async": "off", + "@typescript-eslint/require-array-sort-compare": "off", + "@typescript-eslint/require-await": "off", + "@typescript-eslint/restrict-plus-operands": "off", + "@typescript-eslint/restrict-template-expressions": "off", + "@typescript-eslint/return-await": "off", + "@typescript-eslint/strict-boolean-expressions": "off", + "@typescript-eslint/switch-exhaustiveness-check": "off", + "@typescript-eslint/unbound-method": "off", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "off", + }, + }, + "eslint-recommended": { + "overrides": [ + { + "files": [ + "*.ts", + "*.tsx", + "*.mts", + "*.cts", + ], + "rules": { + "constructor-super": "off", + "getter-return": "off", + "no-const-assign": "off", + "no-dupe-args": "off", + "no-dupe-class-members": "off", + "no-dupe-keys": "off", + "no-func-assign": "off", + "no-import-assign": "off", + "no-new-symbol": "off", + "no-obj-calls": "off", + "no-redeclare": "off", + "no-setter-return": "off", + "no-this-before-super": "off", + "no-undef": "off", + "no-unreachable": "off", + "no-unsafe-negation": "off", + "no-var": "error", + "prefer-const": "error", + "prefer-rest-params": "error", + "prefer-spread": "error", + }, + }, + ], + }, + "recommended": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/triple-slash-reference": "error", + "no-array-constructor": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + }, + }, + "recommended-requiring-type-checking": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "require-await": "off", + }, + }, + "recommended-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "require-await": "off", + }, + }, + "recommended-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/unbound-method": "error", + "no-implied-eval": "off", + "require-await": "off", + }, + }, + "strict": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/ban-ts-comment": [ + "error", + { + "minimumDescriptionLength": 10, + }, + ], + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unified-signatures": "error", + "no-array-constructor": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "no-useless-constructor": "off", + }, + }, + "strict-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": [ + "error", + { + "minimumDescriptionLength": 10, + }, + ], + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/restrict-template-expressions": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/unified-signatures": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-throw-literal": "off", + "no-unused-vars": "off", + "no-useless-constructor": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "strict-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/restrict-template-expressions": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "no-implied-eval": "off", + "no-throw-literal": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "stylistic": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "no-empty-function": "off", + }, + }, + "stylistic-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "dot-notation": "off", + "no-empty-function": "off", + }, + }, + "stylistic-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "dot-notation": "off", + }, + }, + }, + "meta": { + "name": "@typescript-eslint/eslint-plugin", + "version": "7.6.0", + }, + "rules": { + "adjacent-overload-signatures": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require that function overload signatures be consecutive", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/adjacent-overload-signatures", + }, + "messages": { + "adjacentSignature": "All {{name}} signatures should be adjacent.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "array-type": { + "create": [Function], + "defaultOptions": [ + { + "default": "array", + }, + ], + "meta": { + "docs": { + "description": "Require consistently using either \`T[]\` or \`Array\` for arrays", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/array-type", + }, + "fixable": "code", + "messages": { + "errorStringArray": "Array type using '{{className}}<{{type}}>' is forbidden. Use '{{readonlyPrefix}}{{type}}[]' instead.", + "errorStringArraySimple": "Array type using '{{className}}<{{type}}>' is forbidden for simple types. Use '{{readonlyPrefix}}{{type}}[]' instead.", + "errorStringGeneric": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden. Use '{{className}}<{{type}}>' instead.", + "errorStringGenericSimple": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden for non-simple types. Use '{{className}}<{{type}}>' instead.", + }, + "schema": [ + { + "$defs": { + "arrayOption": { + "enum": [ + "array", + "generic", + "array-simple", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "default": { + "$ref": "#/items/0/$defs/arrayOption", + "description": "The array type expected for mutable cases.", + }, + "readonly": { + "$ref": "#/items/0/$defs/arrayOption", + "description": "The array type expected for readonly cases. If omitted, the value for \`default\` will be used.", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "await-thenable": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow awaiting a value that is not a Thenable", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/await-thenable", + }, + "hasSuggestions": true, + "messages": { + "await": "Unexpected \`await\` of a non-Promise (non-"Thenable") value.", + "removeAwait": "Remove unnecessary \`await\`.", + }, + "schema": [], + "type": "problem", + }, + }, + "ban-ts-comment": { + "create": [Function], + "defaultOptions": [ + { + "minimumDescriptionLength": 3, + "ts-check": false, + "ts-expect-error": "allow-with-description", + "ts-ignore": true, + "ts-nocheck": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`@ts-\` comments or require descriptions after directives", + "recommended": { + "recommended": true, + "strict": [ + { + "minimumDescriptionLength": 10, + }, + ], + }, + "url": "https://typescript-eslint.io/rules/ban-ts-comment", + }, + "hasSuggestions": true, + "messages": { + "replaceTsIgnoreWithTsExpectError": "Replace "@ts-ignore" with "@ts-expect-error".", + "tsDirectiveComment": "Do not use "@ts-{{directive}}" because it alters compilation errors.", + "tsDirectiveCommentDescriptionNotMatchPattern": "The description for the "@ts-{{directive}}" directive must match the {{format}} format.", + "tsDirectiveCommentRequiresDescription": "Include a description after the "@ts-{{directive}}" directive to explain why the @ts-{{directive}} is necessary. The description must be {{minimumDescriptionLength}} characters or longer.", + "tsIgnoreInsteadOfExpectError": "Use "@ts-expect-error" instead of "@ts-ignore", as "@ts-ignore" will do nothing if the following line is error-free.", + }, + "schema": [ + { + "$defs": { + "directiveConfigSchema": { + "oneOf": [ + { + "default": true, + "type": "boolean", + }, + { + "enum": [ + "allow-with-description", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "descriptionFormat": { + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "minimumDescriptionLength": { + "default": 3, + "type": "number", + }, + "ts-check": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-expect-error": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-ignore": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-nocheck": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "ban-tslint-comment": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow \`// tslint:\` comments", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/ban-tslint-comment", + }, + "fixable": "code", + "messages": { + "commentDetected": "tslint comment detected: "{{ text }}"", + }, + "schema": [], + "type": "suggestion", + }, + }, + "ban-types": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow certain types", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/ban-types", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "bannedTypeMessage": "Don't use \`{{name}}\` as a type.{{customMessage}}", + "bannedTypeReplacement": "Replace \`{{name}}\` with \`{{replacement}}\`.", + }, + "schema": [ + { + "$defs": { + "banConfig": { + "oneOf": [ + { + "description": "Bans the type with the default message", + "type": "null", + }, + { + "description": "Un-bans the type (useful when paired with \`extendDefaults\`)", + "enum": [ + false, + ], + "type": "boolean", + }, + { + "description": "Bans the type with the default message", + "enum": [ + true, + ], + "type": "boolean", + }, + { + "description": "Bans the type with a custom message", + "type": "string", + }, + { + "additionalProperties": false, + "description": "Bans a type", + "properties": { + "fixWith": { + "description": "Type to autofix replace with. Note that autofixers can be applied automatically - so you need to be careful with this option.", + "type": "string", + }, + "message": { + "description": "Custom error message", + "type": "string", + }, + "suggest": { + "additionalItems": false, + "description": "Types to suggest replacing with.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "extendDefaults": { + "type": "boolean", + }, + "types": { + "additionalProperties": { + "$ref": "#/items/0/$defs/banConfig", + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "block-spacing": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow or enforce spaces inside of blocks after opening block and before closing block", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/block-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "extra": "Unexpected space(s) {{location}} '{{token}}'.", + "missing": "Requires a space {{location}} '{{token}}'.", + }, + "replacedBy": [ + "@stylistic/ts/block-spacing", + ], + "schema": [ + { + "enum": [ + "always", + "never", + ], + }, + ], + "type": "layout", + }, + }, + "brace-style": { + "create": [Function], + "defaultOptions": [ + "1tbs", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent brace style for blocks", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/brace-style", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "blockSameLine": "Statement inside of curly braces should be on next line.", + "nextLineClose": "Closing curly brace does not appear on the same line as the subsequent block.", + "nextLineOpen": "Opening curly brace does not appear on the same line as controlling statement.", + "sameLineClose": "Closing curly brace appears on the same line as the subsequent block.", + "sameLineOpen": "Opening curly brace appears on the same line as controlling statement.", + "singleLineClose": "Closing curly brace should be on the same line as opening curly brace or on the line after the previous block.", + }, + "replacedBy": [ + "@stylistic/ts/brace-style", + ], + "schema": [ + { + "enum": [ + "1tbs", + "stroustrup", + "allman", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowSingleLine": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "class-literal-property-style": { + "create": [Function], + "defaultOptions": [ + "fields", + ], + "meta": { + "docs": { + "description": "Enforce that literals on classes are exposed in a consistent style", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/class-literal-property-style", + }, + "hasSuggestions": true, + "messages": { + "preferFieldStyle": "Literals should be exposed using readonly fields.", + "preferFieldStyleSuggestion": "Replace the literals with readonly fields.", + "preferGetterStyle": "Literals should be exposed using getters.", + "preferGetterStyleSuggestion": "Replace the literals with getters.", + }, + "schema": [ + { + "enum": [ + "fields", + "getters", + ], + "type": "string", + }, + ], + "type": "problem", + }, + }, + "class-methods-use-this": { + "create": [Function], + "defaultOptions": [ + { + "enforceForClassFields": true, + "exceptMethods": [], + "ignoreClassesThatImplementAnInterface": false, + "ignoreOverrideMethods": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce that class methods utilize \`this\`", + "extendsBaseRule": true, + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/class-methods-use-this", + }, + "messages": { + "missingThis": "Expected 'this' to be used by class {{name}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "enforceForClassFields": { + "default": true, + "description": "Enforces that functions used as instance field initializers utilize \`this\`", + "type": "boolean", + }, + "exceptMethods": { + "description": "Allows specified method names to be ignored with this rule", + "items": { + "type": "string", + }, + "type": "array", + }, + "ignoreClassesThatImplementAnInterface": { + "description": "Ignore classes that specifically implement some interface", + "oneOf": [ + { + "description": "Ignore all classes that implement an interface", + "type": "boolean", + }, + { + "description": "Ignore only the public fields of classes that implement an interface", + "enum": [ + "public-fields", + ], + "type": "string", + }, + ], + }, + "ignoreOverrideMethods": { + "description": "Ignore members marked with the \`override\` modifier", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "comma-dangle": { + "create": [Function], + "defaultOptions": [ + "never", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow trailing commas", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/comma-dangle", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "missing": "Missing trailing comma.", + "unexpected": "Unexpected trailing comma.", + }, + "replacedBy": [ + "@stylistic/ts/comma-dangle", + ], + "schema": { + "$defs": { + "value": { + "enum": [ + "always-multiline", + "always", + "never", + "only-multiline", + ], + "type": "string", + }, + "valueWithIgnore": { + "enum": [ + "always-multiline", + "always", + "never", + "only-multiline", + "ignore", + ], + "type": "string", + }, + }, + "additionalItems": false, + "items": [ + { + "oneOf": [ + { + "$ref": "#/$defs/value", + }, + { + "additionalProperties": false, + "properties": { + "arrays": { + "$ref": "#/$defs/valueWithIgnore", + }, + "enums": { + "$ref": "#/$defs/valueWithIgnore", + }, + "exports": { + "$ref": "#/$defs/valueWithIgnore", + }, + "functions": { + "$ref": "#/$defs/valueWithIgnore", + }, + "generics": { + "$ref": "#/$defs/valueWithIgnore", + }, + "imports": { + "$ref": "#/$defs/valueWithIgnore", + }, + "objects": { + "$ref": "#/$defs/valueWithIgnore", + }, + "tuples": { + "$ref": "#/$defs/valueWithIgnore", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "array", + }, + "type": "layout", + }, + }, + "comma-spacing": { + "create": [Function], + "defaultOptions": [ + { + "after": true, + "before": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before and after commas", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/comma-spacing", + }, + "fixable": "whitespace", + "messages": { + "missing": "A space is required {{loc}} ','.", + "unexpected": "There should be no space {{loc}} ','.", + }, + "replacedBy": [ + "@stylistic/ts/comma-spacing", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "after": { + "default": true, + "type": "boolean", + }, + "before": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "consistent-generic-constructors": { + "create": [Function], + "defaultOptions": [ + "constructor", + ], + "meta": { + "docs": { + "description": "Enforce specifying generic type arguments on type annotation or constructor name of a constructor call", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-generic-constructors", + }, + "fixable": "code", + "messages": { + "preferConstructor": "The generic type arguments should be specified as part of the constructor type arguments.", + "preferTypeAnnotation": "The generic type arguments should be specified as part of the type annotation.", + }, + "schema": [ + { + "enum": [ + "type-annotation", + "constructor", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-indexed-object-style": { + "create": [Function], + "defaultOptions": [ + "record", + ], + "meta": { + "docs": { + "description": "Require or disallow the \`Record\` type", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-indexed-object-style", + }, + "fixable": "code", + "messages": { + "preferIndexSignature": "An index signature is preferred over a record.", + "preferRecord": "A record is preferred over an index signature.", + }, + "schema": [ + { + "enum": [ + "record", + "index-signature", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-return": { + "create": [Function], + "defaultOptions": [ + { + "treatUndefinedAsUnspecified": false, + }, + ], + "meta": { + "docs": { + "description": "Require \`return\` statements to either always or never specify values", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/consistent-return", + }, + "hasSuggestions": undefined, + "messages": { + "missingReturn": "Expected to return a value at the end of {{name}}.", + "missingReturnValue": "{{name}} expected a return value.", + "unexpectedReturnValue": "{{name}} expected no return value.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "treatUndefinedAsUnspecified": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-assertions": { + "create": [Function], + "defaultOptions": [ + { + "assertionStyle": "as", + "objectLiteralTypeAssertions": "allow", + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type assertions", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-type-assertions", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "angle-bracket": "Use '<{{cast}}>' instead of 'as {{cast}}'.", + "as": "Use 'as {{cast}}' instead of '<{{cast}}>'.", + "never": "Do not use any type assertions.", + "replaceObjectTypeAssertionWithAnnotation": "Use const x: {{cast}} = { ... } instead.", + "replaceObjectTypeAssertionWithSatisfies": "Use const x = { ... } satisfies {{cast}} instead.", + "unexpectedObjectTypeAssertion": "Always prefer const x: T = { ... }.", + }, + "schema": [ + { + "oneOf": [ + { + "additionalProperties": false, + "properties": { + "assertionStyle": { + "enum": [ + "never", + ], + "type": "string", + }, + }, + "required": [ + "assertionStyle", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "assertionStyle": { + "enum": [ + "as", + "angle-bracket", + ], + "type": "string", + }, + "objectLiteralTypeAssertions": { + "enum": [ + "allow", + "allow-as-parameter", + "never", + ], + "type": "string", + }, + }, + "required": [ + "assertionStyle", + ], + "type": "object", + }, + ], + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-definitions": { + "create": [Function], + "defaultOptions": [ + "interface", + ], + "meta": { + "docs": { + "description": "Enforce type definitions to consistently use either \`interface\` or \`type\`", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-type-definitions", + }, + "fixable": "code", + "messages": { + "interfaceOverType": "Use an \`interface\` instead of a \`type\`.", + "typeOverInterface": "Use a \`type\` instead of an \`interface\`.", + }, + "schema": [ + { + "enum": [ + "interface", + "type", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-exports": { + "create": [Function], + "defaultOptions": [ + { + "fixMixedExportsWithInlineTypeSpecifier": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type exports", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/consistent-type-exports", + }, + "fixable": "code", + "messages": { + "multipleExportsAreTypes": "Type exports {{exportNames}} are not values and should be exported using \`export type\`.", + "singleExportIsType": "Type export {{exportNames}} is not a value and should be exported using \`export type\`.", + "typeOverValue": "All exports in the declaration are only used as types. Use \`export type\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "fixMixedExportsWithInlineTypeSpecifier": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-imports": { + "create": [Function], + "defaultOptions": [ + { + "disallowTypeAnnotations": true, + "fixStyle": "separate-type-imports", + "prefer": "type-imports", + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type imports", + "url": "https://typescript-eslint.io/rules/consistent-type-imports", + }, + "fixable": "code", + "messages": { + "avoidImportType": "Use an \`import\` instead of an \`import type\`.", + "noImportTypeAnnotations": "\`import()\` type annotations are forbidden.", + "someImportsAreOnlyTypes": "Imports {{typeImports}} are only used as type.", + "typeOverValue": "All imports in the declaration are only used as types. Use \`import type\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "disallowTypeAnnotations": { + "type": "boolean", + }, + "fixStyle": { + "enum": [ + "separate-type-imports", + "inline-type-imports", + ], + "type": "string", + }, + "prefer": { + "enum": [ + "type-imports", + "no-type-imports", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "default-param-last": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce default parameters to be last", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/default-param-last", + }, + "messages": { + "shouldBeLast": "Default parameters should be last.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "dot-notation": { + "create": [Function], + "defaultOptions": [ + { + "allowIndexSignaturePropertyAccess": false, + "allowKeywords": true, + "allowPattern": "", + "allowPrivateClassPropertyAccess": false, + "allowProtectedClassPropertyAccess": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce dot notation whenever possible", + "extendsBaseRule": true, + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/dot-notation", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "useBrackets": ".{{key}} is a syntax error.", + "useDot": "[{{key}}] is better written in dot notation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowIndexSignaturePropertyAccess": { + "default": false, + "type": "boolean", + }, + "allowKeywords": { + "default": true, + "type": "boolean", + }, + "allowPattern": { + "default": "", + "type": "string", + }, + "allowPrivateClassPropertyAccess": { + "default": false, + "type": "boolean", + }, + "allowProtectedClassPropertyAccess": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "explicit-function-return-type": { + "create": [Function], + "defaultOptions": [ + { + "allowConciseArrowFunctionExpressionsStartingWithVoid": false, + "allowDirectConstAssertionInArrowFunctions": true, + "allowExpressions": false, + "allowFunctionsWithoutTypeParameters": false, + "allowHigherOrderFunctions": true, + "allowIIFEs": false, + "allowTypedFunctionExpressions": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Require explicit return types on functions and class methods", + "url": "https://typescript-eslint.io/rules/explicit-function-return-type", + }, + "messages": { + "missingReturnType": "Missing return type on function.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConciseArrowFunctionExpressionsStartingWithVoid": { + "description": "Whether to allow arrow functions that start with the \`void\` keyword.", + "type": "boolean", + }, + "allowDirectConstAssertionInArrowFunctions": { + "description": "Whether to ignore arrow functions immediately returning a \`as const\` value.", + "type": "boolean", + }, + "allowExpressions": { + "description": "Whether to ignore function expressions (functions which are not part of a declaration).", + "type": "boolean", + }, + "allowFunctionsWithoutTypeParameters": { + "description": "Whether to ignore functions that don't have generic type parameters.", + "type": "boolean", + }, + "allowHigherOrderFunctions": { + "description": "Whether to ignore functions immediately returning another function expression.", + "type": "boolean", + }, + "allowIIFEs": { + "description": "Whether to ignore immediately invoked function expressions (IIFEs).", + "type": "boolean", + }, + "allowTypedFunctionExpressions": { + "description": "Whether to ignore type annotations on the variable of function expressions.", + "type": "boolean", + }, + "allowedNames": { + "description": "An array of function/method names that will not have their arguments or return values checked.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "explicit-member-accessibility": { + "create": [Function], + "defaultOptions": [ + { + "accessibility": "explicit", + }, + ], + "meta": { + "docs": { + "description": "Require explicit accessibility modifiers on class properties and methods", + "url": "https://typescript-eslint.io/rules/explicit-member-accessibility", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "addExplicitAccessibility": "Add '{{ type }}' accessibility modifier", + "missingAccessibility": "Missing accessibility modifier on {{type}} {{name}}.", + "unwantedPublicAccessibility": "Public accessibility modifier on {{type}} {{name}}.", + }, + "schema": [ + { + "$defs": { + "accessibilityLevel": { + "oneOf": [ + { + "description": "Always require an accessor.", + "enum": [ + "explicit", + ], + "type": "string", + }, + { + "description": "Require an accessor except when public.", + "enum": [ + "no-public", + ], + "type": "string", + }, + { + "description": "Never check whether there is an accessor.", + "enum": [ + "off", + ], + "type": "string", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "accessibility": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "ignoredMethodNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "accessors": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "constructors": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "methods": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "parameterProperties": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "properties": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "explicit-module-boundary-types": { + "create": [Function], + "defaultOptions": [ + { + "allowArgumentsExplicitlyTypedAsAny": false, + "allowDirectConstAssertionInArrowFunctions": true, + "allowHigherOrderFunctions": true, + "allowTypedFunctionExpressions": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Require explicit return and argument types on exported functions' and classes' public class methods", + "url": "https://typescript-eslint.io/rules/explicit-module-boundary-types", + }, + "messages": { + "anyTypedArg": "Argument '{{name}}' should be typed with a non-any type.", + "anyTypedArgUnnamed": "{{type}} argument should be typed with a non-any type.", + "missingArgType": "Argument '{{name}}' should be typed.", + "missingArgTypeUnnamed": "{{type}} argument should be typed.", + "missingReturnType": "Missing return type on function.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowArgumentsExplicitlyTypedAsAny": { + "description": "Whether to ignore arguments that are explicitly typed as \`any\`.", + "type": "boolean", + }, + "allowDirectConstAssertionInArrowFunctions": { + "description": "Whether to ignore return type annotations on body-less arrow functions that return an \`as const\` type assertion. +You must still type the parameters of the function.", + "type": "boolean", + }, + "allowHigherOrderFunctions": { + "description": "Whether to ignore return type annotations on functions immediately returning another function expression. +You must still type the parameters of the function.", + "type": "boolean", + }, + "allowTypedFunctionExpressions": { + "description": "Whether to ignore type annotations on the variable of a function expression.", + "type": "boolean", + }, + "allowedNames": { + "description": "An array of function/method names that will not have their arguments or return values checked.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "func-call-spacing": { + "create": [Function], + "defaultOptions": [ + "never", + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow spacing between function identifiers and their invocations", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/func-call-spacing", + }, + "fixable": "whitespace", + "messages": { + "missing": "Missing space between function name and paren.", + "unexpectedNewline": "Unexpected newline between function name and paren.", + "unexpectedWhitespace": "Unexpected whitespace between function name and paren.", + }, + "replacedBy": [ + "@stylistic/ts/func-call-spacing", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "always", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowNewlines": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "indent": { + "create": [Function], + "defaultOptions": [ + 4, + { + "SwitchCase": 1, + "flatTernaryExpressions": false, + "ignoredNodes": [], + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent indentation", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/indent", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "wrongIndentation": "Expected indentation of {{expected}} but found {{actual}}.", + }, + "replacedBy": [ + "@stylistic/ts/indent", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "tab", + ], + }, + { + "minimum": 0, + "type": "integer", + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "ArrayExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "CallExpression": { + "additionalProperties": false, + "properties": { + "arguments": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "FunctionDeclaration": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + "parameters": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "FunctionExpression": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + "parameters": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "ImportDeclaration": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "MemberExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "off", + ], + }, + ], + }, + "ObjectExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "StaticBlock": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + }, + "type": "object", + }, + "SwitchCase": { + "default": 0, + "minimum": 0, + "type": "integer", + }, + "VariableDeclarator": { + "oneOf": [ + { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "const": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "let": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "var": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + ], + }, + "flatTernaryExpressions": { + "default": false, + "type": "boolean", + }, + "ignoreComments": { + "default": false, + "type": "boolean", + }, + "ignoredNodes": { + "items": { + "not": { + "pattern": ":exit$", + }, + "type": "string", + }, + "type": "array", + }, + "offsetTernaryExpressions": { + "default": false, + "type": "boolean", + }, + "outerIIFEBody": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "init-declarations": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "docs": { + "description": "Require or disallow initialization in variable declarations", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/init-declarations", + }, + "hasSuggestions": undefined, + "messages": { + "initialized": "Variable '{{idName}}' should be initialized on declaration.", + "notInitialized": "Variable '{{idName}}' should not be initialized on declaration.", + }, + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "always", + ], + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "ignoreForLoopInit": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "suggestion", + }, + }, + "key-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing between property names and type annotations in types and interfaces", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/key-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "extraKey": "Extra space after {{computed}}key '{{key}}'.", + "extraValue": "Extra space before value for {{computed}}key '{{key}}'.", + "missingKey": "Missing space after {{computed}}key '{{key}}'.", + "missingValue": "Missing space before value for {{computed}}key '{{key}}'.", + }, + "replacedBy": [ + "@stylistic/ts/key-spacing", + ], + "schema": [ + { + "anyOf": [ + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "align": { + "anyOf": [ + { + "enum": [ + "colon", + "value", + ], + }, + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + ], + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "multiLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "align": { + "anyOf": [ + { + "enum": [ + "colon", + "value", + ], + }, + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + ], + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + "singleLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "align": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + "multiLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + "singleLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "keyword-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before and after keywords", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/keyword-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "expectedAfter": "Expected space(s) after "{{value}}".", + "expectedBefore": "Expected space(s) before "{{value}}".", + "unexpectedAfter": "Unexpected space(s) after "{{value}}".", + "unexpectedBefore": "Unexpected space(s) before "{{value}}".", + }, + "replacedBy": [ + "@stylistic/ts/keyword-spacing", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "after": { + "default": true, + "type": "boolean", + }, + "before": { + "default": true, + "type": "boolean", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "abstract": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "as": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "async": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "await": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "boolean": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "break": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "byte": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "case": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "catch": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "char": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "class": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "const": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "continue": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "debugger": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "default": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "delete": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "do": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "double": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "else": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "enum": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "export": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "extends": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "false": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "final": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "finally": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "float": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "for": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "from": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "function": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "get": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "goto": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "if": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "implements": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "import": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "in": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "instanceof": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "int": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "interface": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "let": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "long": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "native": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "new": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "null": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "of": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "package": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "private": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "protected": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "public": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "return": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "set": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "short": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "static": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "super": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "switch": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "synchronized": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "this": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "throw": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "throws": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "transient": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "true": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "try": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "type": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "typeof": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "var": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "void": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "volatile": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "while": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "with": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "yield": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "lines-around-comment": { + "create": [Function], + "defaultOptions": [ + { + "beforeBlockComment": true, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require empty lines around comments", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/lines-around-comment", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "after": "Expected line after comment.", + "before": "Expected line before comment.", + }, + "replacedBy": [ + "@stylistic/ts/lines-around-comment", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "afterBlockComment": { + "default": false, + "type": "boolean", + }, + "afterLineComment": { + "default": false, + "type": "boolean", + }, + "allowArrayEnd": { + "type": "boolean", + }, + "allowArrayStart": { + "type": "boolean", + }, + "allowBlockEnd": { + "default": false, + "type": "boolean", + }, + "allowBlockStart": { + "default": false, + "type": "boolean", + }, + "allowClassEnd": { + "type": "boolean", + }, + "allowClassStart": { + "type": "boolean", + }, + "allowEnumEnd": { + "type": "boolean", + }, + "allowEnumStart": { + "type": "boolean", + }, + "allowInterfaceEnd": { + "type": "boolean", + }, + "allowInterfaceStart": { + "type": "boolean", + }, + "allowModuleEnd": { + "type": "boolean", + }, + "allowModuleStart": { + "type": "boolean", + }, + "allowObjectEnd": { + "type": "boolean", + }, + "allowObjectStart": { + "type": "boolean", + }, + "allowTypeEnd": { + "type": "boolean", + }, + "allowTypeStart": { + "type": "boolean", + }, + "applyDefaultIgnorePatterns": { + "type": "boolean", + }, + "beforeBlockComment": { + "default": true, + "type": "boolean", + }, + "beforeLineComment": { + "default": false, + "type": "boolean", + }, + "ignorePattern": { + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "lines-between-class-members": { + "create": [Function], + "defaultOptions": [ + "always", + { + "exceptAfterOverload": true, + "exceptAfterSingleLine": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow an empty line between class members", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/lines-between-class-members", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "always": "Expected blank line between class members.", + "never": "Unexpected blank line between class members.", + }, + "replacedBy": [ + "@stylistic/ts/lines-between-class-members", + ], + "schema": [ + { + "anyOf": [ + { + "additionalProperties": false, + "properties": { + "enforce": { + "items": { + "additionalProperties": false, + "properties": { + "blankLine": { + "enum": [ + "always", + "never", + ], + }, + "next": { + "enum": [ + "method", + "field", + "*", + ], + }, + "prev": { + "enum": [ + "method", + "field", + "*", + ], + }, + }, + "required": [ + "blankLine", + "prev", + "next", + ], + "type": "object", + }, + "minItems": 1, + "type": "array", + }, + }, + "required": [ + "enforce", + ], + "type": "object", + }, + { + "enum": [ + "always", + "never", + ], + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "exceptAfterOverload": { + "default": true, + "type": "boolean", + }, + "exceptAfterSingleLine": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "max-params": { + "create": [Function], + "defaultOptions": [ + { + "countVoidThis": false, + "max": 3, + }, + ], + "meta": { + "docs": { + "description": "Enforce a maximum number of parameters in function definitions", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/max-params", + }, + "messages": { + "exceed": "{{name}} has too many parameters ({{count}}). Maximum allowed is {{max}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "countVoidThis": { + "type": "boolean", + }, + "max": { + "minimum": 0, + "type": "integer", + }, + "maximum": { + "minimum": 0, + "type": "integer", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "member-delimiter-style": { + "create": [Function], + "defaultOptions": [ + { + "multiline": { + "delimiter": "semi", + "requireLast": true, + }, + "multilineDetection": "brackets", + "singleline": { + "delimiter": "semi", + "requireLast": false, + }, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require a specific member delimiter style for interfaces and type literals", + "url": "https://typescript-eslint.io/rules/member-delimiter-style", + }, + "fixable": "whitespace", + "messages": { + "expectedComma": "Expected a comma.", + "expectedSemi": "Expected a semicolon.", + "unexpectedComma": "Unexpected separator (,).", + "unexpectedSemi": "Unexpected separator (;).", + }, + "replacedBy": [ + "@stylistic/ts/member-delimiter-style", + ], + "schema": [ + { + "$defs": { + "delimiterConfig": { + "additionalProperties": false, + "properties": { + "multiline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/multiLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + "singleline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/singleLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + "multiLineOption": { + "enum": [ + "none", + "semi", + "comma", + ], + "type": "string", + }, + "singleLineOption": { + "enum": [ + "semi", + "comma", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "multiline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/multiLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + "multilineDetection": { + "enum": [ + "brackets", + "last-member", + ], + "type": "string", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "interface": { + "$ref": "#/items/0/$defs/delimiterConfig", + }, + "typeLiteral": { + "$ref": "#/items/0/$defs/delimiterConfig", + }, + }, + "type": "object", + }, + "singleline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/singleLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "member-ordering": { + "create": [Function], + "defaultOptions": [ + { + "default": { + "memberTypes": [ + "signature", + "call-signature", + "public-static-field", + "protected-static-field", + "private-static-field", + "#private-static-field", + "public-decorated-field", + "protected-decorated-field", + "private-decorated-field", + "public-instance-field", + "protected-instance-field", + "private-instance-field", + "#private-instance-field", + "public-abstract-field", + "protected-abstract-field", + "public-field", + "protected-field", + "private-field", + "#private-field", + "static-field", + "instance-field", + "abstract-field", + "decorated-field", + "field", + "static-initialization", + "public-constructor", + "protected-constructor", + "private-constructor", + "constructor", + "public-static-accessor", + "protected-static-accessor", + "private-static-accessor", + "#private-static-accessor", + "public-decorated-accessor", + "protected-decorated-accessor", + "private-decorated-accessor", + "public-instance-accessor", + "protected-instance-accessor", + "private-instance-accessor", + "#private-instance-accessor", + "public-abstract-accessor", + "protected-abstract-accessor", + "public-accessor", + "protected-accessor", + "private-accessor", + "#private-accessor", + "static-accessor", + "instance-accessor", + "abstract-accessor", + "decorated-accessor", + "accessor", + "public-static-get", + "protected-static-get", + "private-static-get", + "#private-static-get", + "public-decorated-get", + "protected-decorated-get", + "private-decorated-get", + "public-instance-get", + "protected-instance-get", + "private-instance-get", + "#private-instance-get", + "public-abstract-get", + "protected-abstract-get", + "public-get", + "protected-get", + "private-get", + "#private-get", + "static-get", + "instance-get", + "abstract-get", + "decorated-get", + "get", + "public-static-set", + "protected-static-set", + "private-static-set", + "#private-static-set", + "public-decorated-set", + "protected-decorated-set", + "private-decorated-set", + "public-instance-set", + "protected-instance-set", + "private-instance-set", + "#private-instance-set", + "public-abstract-set", + "protected-abstract-set", + "public-set", + "protected-set", + "private-set", + "#private-set", + "static-set", + "instance-set", + "abstract-set", + "decorated-set", + "set", + "public-static-method", + "protected-static-method", + "private-static-method", + "#private-static-method", + "public-decorated-method", + "protected-decorated-method", + "private-decorated-method", + "public-instance-method", + "protected-instance-method", + "private-instance-method", + "#private-instance-method", + "public-abstract-method", + "protected-abstract-method", + "public-method", + "protected-method", + "private-method", + "#private-method", + "static-method", + "instance-method", + "abstract-method", + "decorated-method", + "method", + ], + }, + }, + ], + "meta": { + "docs": { + "description": "Require a consistent member declaration order", + "url": "https://typescript-eslint.io/rules/member-ordering", + }, + "messages": { + "incorrectGroupOrder": "Member {{name}} should be declared before all {{rank}} definitions.", + "incorrectOrder": "Member {{member}} should be declared before member {{beforeMember}}.", + "incorrectRequiredMembersOrder": "Member {{member}} should be declared after all {{optionalOrRequired}} members.", + }, + "schema": [ + { + "$defs": { + "allItems": { + "enum": [ + "readonly-signature", + "signature", + "readonly-field", + "public-readonly-field", + "public-decorated-readonly-field", + "decorated-readonly-field", + "static-readonly-field", + "public-static-readonly-field", + "instance-readonly-field", + "public-instance-readonly-field", + "abstract-readonly-field", + "public-abstract-readonly-field", + "protected-readonly-field", + "protected-decorated-readonly-field", + "protected-static-readonly-field", + "protected-instance-readonly-field", + "protected-abstract-readonly-field", + "private-readonly-field", + "private-decorated-readonly-field", + "private-static-readonly-field", + "private-instance-readonly-field", + "#private-readonly-field", + "#private-static-readonly-field", + "#private-instance-readonly-field", + "field", + "public-field", + "public-decorated-field", + "decorated-field", + "static-field", + "public-static-field", + "instance-field", + "public-instance-field", + "abstract-field", + "public-abstract-field", + "protected-field", + "protected-decorated-field", + "protected-static-field", + "protected-instance-field", + "protected-abstract-field", + "private-field", + "private-decorated-field", + "private-static-field", + "private-instance-field", + "#private-field", + "#private-static-field", + "#private-instance-field", + "method", + "public-method", + "public-decorated-method", + "decorated-method", + "static-method", + "public-static-method", + "instance-method", + "public-instance-method", + "abstract-method", + "public-abstract-method", + "protected-method", + "protected-decorated-method", + "protected-static-method", + "protected-instance-method", + "protected-abstract-method", + "private-method", + "private-decorated-method", + "private-static-method", + "private-instance-method", + "#private-method", + "#private-static-method", + "#private-instance-method", + "call-signature", + "constructor", + "public-constructor", + "protected-constructor", + "private-constructor", + "accessor", + "public-accessor", + "public-decorated-accessor", + "decorated-accessor", + "static-accessor", + "public-static-accessor", + "instance-accessor", + "public-instance-accessor", + "abstract-accessor", + "public-abstract-accessor", + "protected-accessor", + "protected-decorated-accessor", + "protected-static-accessor", + "protected-instance-accessor", + "protected-abstract-accessor", + "private-accessor", + "private-decorated-accessor", + "private-static-accessor", + "private-instance-accessor", + "#private-accessor", + "#private-static-accessor", + "#private-instance-accessor", + "get", + "public-get", + "public-decorated-get", + "decorated-get", + "static-get", + "public-static-get", + "instance-get", + "public-instance-get", + "abstract-get", + "public-abstract-get", + "protected-get", + "protected-decorated-get", + "protected-static-get", + "protected-instance-get", + "protected-abstract-get", + "private-get", + "private-decorated-get", + "private-static-get", + "private-instance-get", + "#private-get", + "#private-static-get", + "#private-instance-get", + "set", + "public-set", + "public-decorated-set", + "decorated-set", + "static-set", + "public-static-set", + "instance-set", + "public-instance-set", + "abstract-set", + "public-abstract-set", + "protected-set", + "protected-decorated-set", + "protected-static-set", + "protected-instance-set", + "protected-abstract-set", + "private-set", + "private-decorated-set", + "private-static-set", + "private-instance-set", + "#private-set", + "#private-static-set", + "#private-instance-set", + "static-initialization", + "static-static-initialization", + "public-static-static-initialization", + "instance-static-initialization", + "public-instance-static-initialization", + "abstract-static-initialization", + "public-abstract-static-initialization", + "protected-static-static-initialization", + "protected-instance-static-initialization", + "protected-abstract-static-initialization", + "private-static-static-initialization", + "private-instance-static-initialization", + "#private-static-static-initialization", + "#private-instance-static-initialization", + ], + "type": "string", + }, + "baseConfig": { + "oneOf": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/allItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/allItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "additionalProperties": false, + "properties": { + "memberTypes": { + "oneOf": [ + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/allItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/allItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + }, + "optionalityOrder": { + "$ref": "#/items/0/$defs/optionalityOrderOptions", + }, + "order": { + "$ref": "#/items/0/$defs/orderOptions", + }, + }, + "type": "object", + }, + ], + }, + "optionalityOrderOptions": { + "enum": [ + "optional-first", + "required-first", + ], + "type": "string", + }, + "orderOptions": { + "enum": [ + "alphabetically", + "alphabetically-case-insensitive", + "as-written", + "natural", + "natural-case-insensitive", + ], + "type": "string", + }, + "typeItems": { + "enum": [ + "readonly-signature", + "signature", + "readonly-field", + "field", + "method", + "constructor", + ], + "type": "string", + }, + "typesConfig": { + "oneOf": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/typeItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/typeItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "additionalProperties": false, + "properties": { + "memberTypes": { + "oneOf": [ + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/typeItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/typeItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + }, + "optionalityOrder": { + "$ref": "#/items/0/$defs/optionalityOrderOptions", + }, + "order": { + "$ref": "#/items/0/$defs/orderOptions", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "classExpressions": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "classes": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "default": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "interfaces": { + "$ref": "#/items/0/$defs/typesConfig", + }, + "typeLiterals": { + "$ref": "#/items/0/$defs/typesConfig", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "method-signature-style": { + "create": [Function], + "defaultOptions": [ + "property", + ], + "meta": { + "docs": { + "description": "Enforce using a particular method signature syntax", + "url": "https://typescript-eslint.io/rules/method-signature-style", + }, + "fixable": "code", + "messages": { + "errorMethod": "Shorthand method signature is forbidden. Use a function property instead.", + "errorProperty": "Function property signature is forbidden. Use a method shorthand instead.", + }, + "schema": [ + { + "enum": [ + "property", + "method", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "naming-convention": { + "create": [Function], + "defaultOptions": [ + { + "format": [ + "camelCase", + ], + "leadingUnderscore": "allow", + "selector": "default", + "trailingUnderscore": "allow", + }, + { + "format": [ + "camelCase", + "PascalCase", + ], + "selector": "import", + }, + { + "format": [ + "camelCase", + "UPPER_CASE", + ], + "leadingUnderscore": "allow", + "selector": "variable", + "trailingUnderscore": "allow", + }, + { + "format": [ + "PascalCase", + ], + "selector": "typeLike", + }, + ], + "meta": { + "docs": { + "description": "Enforce naming conventions for everything across a codebase", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/naming-convention", + }, + "messages": { + "doesNotMatchFormat": "{{type}} name \`{{name}}\` must match one of the following formats: {{formats}}", + "doesNotMatchFormatTrimmed": "{{type}} name \`{{name}}\` trimmed as \`{{processedName}}\` must match one of the following formats: {{formats}}", + "missingAffix": "{{type}} name \`{{name}}\` must have one of the following {{position}}es: {{affixes}}", + "missingUnderscore": "{{type}} name \`{{name}}\` must have {{count}} {{position}} underscore(s).", + "satisfyCustom": "{{type}} name \`{{name}}\` must {{regexMatch}} the RegExp: {{regex}}", + "unexpectedUnderscore": "{{type}} name \`{{name}}\` must not have a {{position}} underscore.", + }, + "schema": { + "$defs": { + "formatOptionsConfig": { + "oneOf": [ + { + "additionalItems": false, + "items": { + "$ref": "#/$defs/predefinedFormats", + }, + "type": "array", + }, + { + "type": "null", + }, + ], + }, + "matchRegexConfig": { + "additionalProperties": false, + "properties": { + "match": { + "type": "boolean", + }, + "regex": { + "type": "string", + }, + }, + "required": [ + "match", + "regex", + ], + "type": "object", + }, + "predefinedFormats": { + "enum": [ + "camelCase", + "strictCamelCase", + "PascalCase", + "StrictPascalCase", + "snake_case", + "UPPER_CASE", + ], + "type": "string", + }, + "prefixSuffixConfig": { + "additionalItems": false, + "items": { + "minLength": 1, + "type": "string", + }, + "type": "array", + }, + "typeModifiers": { + "enum": [ + "boolean", + "string", + "number", + "function", + "array", + ], + "type": "string", + }, + "underscoreOptions": { + "enum": [ + "forbid", + "allow", + "require", + "requireDouble", + "allowDouble", + "allowSingleOrDouble", + ], + "type": "string", + }, + }, + "additionalItems": false, + "items": { + "oneOf": [ + { + "additionalProperties": false, + "description": "Multiple selectors in one config", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "readonly", + "static", + "public", + "protected", + "private", + "#private", + "abstract", + "destructured", + "global", + "exported", + "unused", + "requiresQuotes", + "override", + "async", + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "additionalItems": false, + "items": { + "enum": [ + "default", + "variableLike", + "memberLike", + "typeLike", + "method", + "property", + "accessor", + "variable", + "function", + "parameter", + "parameterProperty", + "classicAccessor", + "enumMember", + "classMethod", + "objectLiteralMethod", + "typeMethod", + "classProperty", + "objectLiteralProperty", + "typeProperty", + "autoAccessor", + "class", + "interface", + "typeAlias", + "enum", + "typeParameter", + "import", + ], + "type": "string", + }, + "type": "array", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'default'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "readonly", + "static", + "public", + "protected", + "private", + "#private", + "abstract", + "destructured", + "global", + "exported", + "unused", + "requiresQuotes", + "override", + "async", + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "default", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'variableLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "variableLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'variable'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "destructured", + "exported", + "global", + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "variable", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'function'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "global", + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "function", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'parameter'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "destructured", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "parameter", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'memberLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "memberLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'objectLiteralProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "objectLiteralProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "readonly", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'parameterProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "private", + "protected", + "public", + "readonly", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "parameterProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'property'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "property", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'objectLiteralMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "objectLiteralMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'method'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "method", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classicAccessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classicAccessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'autoAccessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "autoAccessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'accessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "accessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'enumMember'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "enumMember", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'class'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "class", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'interface'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "interface", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeAlias'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeAlias", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'enum'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "enum", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeParameter'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeParameter", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'import'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "import", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + ], + }, + "type": "array", + }, + "type": "suggestion", + }, + }, + "no-array-constructor": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow generic \`Array\` constructors", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-array-constructor", + }, + "fixable": "code", + "messages": { + "useLiteral": "The array literal notation [] is preferable.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-array-delete": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow using the \`delete\` operator on array values", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-array-delete", + }, + "hasSuggestions": true, + "messages": { + "noArrayDelete": "Using the \`delete\` operator with an array expression is unsafe.", + "useSplice": "Use \`array.splice()\` instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-base-to-string": { + "create": [Function], + "defaultOptions": [ + { + "ignoredTypeNames": [ + "Error", + "RegExp", + "URL", + "URLSearchParams", + ], + }, + ], + "meta": { + "docs": { + "description": "Require \`.toString()\` to only be called on objects which provide useful information when stringified", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-base-to-string", + }, + "messages": { + "baseToString": "'{{name}}' {{certainty}} evaluate to '[object Object]' when stringified.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoredTypeNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-confusing-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertion in locations that may be confusing", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-confusing-non-null-assertion", + }, + "hasSuggestions": true, + "messages": { + "confusingAssign": "Confusing combinations of non-null assertion and equal test like "a! = b", which looks very similar to not equal "a != b".", + "confusingEqual": "Confusing combinations of non-null assertion and equal test like "a! == b", which looks very similar to not equal "a !== b".", + "notNeedInAssign": "Unnecessary non-null assertion (!) in assignment left hand.", + "notNeedInEqualTest": "Unnecessary non-null assertion (!) in equal test.", + "wrapUpLeft": "Wrap up left hand to avoid putting non-null assertion "!" and "=" together.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-confusing-void-expression": { + "create": [Function], + "defaultOptions": [ + { + "ignoreArrowShorthand": false, + "ignoreVoidOperator": false, + }, + ], + "meta": { + "docs": { + "description": "Require expressions of type void to appear in statement position", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-confusing-void-expression", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "invalidVoidExpr": "Placing a void expression inside another expression is forbidden. Move it to its own statement instead.", + "invalidVoidExprArrow": "Returning a void expression from an arrow function shorthand is forbidden. Please add braces to the arrow function.", + "invalidVoidExprArrowWrapVoid": "Void expressions returned from an arrow function shorthand must be marked explicitly with the \`void\` operator.", + "invalidVoidExprReturn": "Returning a void expression from a function is forbidden. Please move it before the \`return\` statement.", + "invalidVoidExprReturnLast": "Returning a void expression from a function is forbidden. Please remove the \`return\` statement.", + "invalidVoidExprReturnWrapVoid": "Void expressions returned from a function must be marked explicitly with the \`void\` operator.", + "invalidVoidExprWrapVoid": "Void expressions used inside another expression must be moved to its own statement or marked explicitly with the \`void\` operator.", + "voidExprWrapVoid": "Mark with an explicit \`void\` operator.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreArrowShorthand": { + "type": "boolean", + }, + "ignoreVoidOperator": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-dupe-class-members": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow duplicate class members", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-dupe-class-members", + }, + "hasSuggestions": undefined, + "messages": { + "unexpected": "Duplicate name '{{name}}'.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-duplicate-enum-values": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow duplicate enum member values", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-duplicate-enum-values", + }, + "hasSuggestions": false, + "messages": { + "duplicateValue": "Duplicate enum member value {{value}}.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-duplicate-type-constituents": { + "create": [Function], + "defaultOptions": [ + { + "ignoreIntersections": false, + "ignoreUnions": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow duplicate constituents of union or intersection types", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-duplicate-type-constituents", + }, + "fixable": "code", + "messages": { + "duplicate": "{{type}} type constituent is duplicated with {{previous}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreIntersections": { + "type": "boolean", + }, + "ignoreUnions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-dynamic-delete": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow using the \`delete\` operator on computed key expressions", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-dynamic-delete", + }, + "fixable": "code", + "messages": { + "dynamicDelete": "Do not delete dynamically computed property keys.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-empty-function": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow empty functions", + "extendsBaseRule": true, + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-empty-function", + }, + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unexpected empty {{name}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "enum": [ + "functions", + "arrowFunctions", + "generatorFunctions", + "methods", + "generatorMethods", + "getters", + "setters", + "constructors", + "private-constructors", + "protected-constructors", + "asyncFunctions", + "asyncMethods", + "decoratedFunctions", + "overrideMethods", + ], + "type": "string", + }, + "type": "array", + "uniqueItems": true, + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-empty-interface": { + "create": [Function], + "defaultOptions": [ + { + "allowSingleExtends": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the declaration of empty interfaces", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-empty-interface", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "noEmpty": "An empty interface is equivalent to \`{}\`.", + "noEmptyWithSuper": "An interface declaring no members is equivalent to its supertype.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowSingleExtends": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-explicit-any": { + "create": [Function], + "defaultOptions": [ + { + "fixToUnknown": false, + "ignoreRestArgs": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the \`any\` type", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-explicit-any", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "suggestNever": "Use \`never\` instead, this is useful when instantiating generic type parameters that you don't need to know the type of.", + "suggestUnknown": "Use \`unknown\` instead, this will force you to explicitly, and safely assert the type is correct.", + "unexpectedAny": "Unexpected any. Specify a different type.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "fixToUnknown": { + "description": "Whether to enable auto-fixing in which the \`any\` type is converted to the \`unknown\` type.", + "type": "boolean", + }, + "ignoreRestArgs": { + "description": "Whether to ignore rest parameter arrays.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-extra-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow extra non-null assertions", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-extra-non-null-assertion", + }, + "fixable": "code", + "messages": { + "noExtraNonNullAssertion": "Forbidden extra non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-extra-parens": { + "create": [Function], + "defaultOptions": [ + "all", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow unnecessary parentheses", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-extra-parens", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unnecessary parentheses around expression.", + }, + "replacedBy": [ + "@stylistic/ts/no-extra-parens", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "functions", + ], + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "all", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowParensAfterCommentPattern": { + "type": "string", + }, + "conditionalAssign": { + "type": "boolean", + }, + "enforceForArrowConditionals": { + "type": "boolean", + }, + "enforceForFunctionPrototypeMethods": { + "type": "boolean", + }, + "enforceForNewInMemberExpressions": { + "type": "boolean", + }, + "enforceForSequenceExpressions": { + "type": "boolean", + }, + "ignoreJSX": { + "enum": [ + "none", + "all", + "single-line", + "multi-line", + ], + }, + "nestedBinaryExpressions": { + "type": "boolean", + }, + "returnAssign": { + "type": "boolean", + }, + "ternaryOperandBinaryExpressions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "no-extra-semi": { + "create": [Function], + "defaultOptions": [], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow unnecessary semicolons", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-extra-semi", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unnecessary semicolon.", + }, + "replacedBy": [ + "@stylistic/ts/no-extra-semi", + ], + "schema": [], + "type": "suggestion", + }, + }, + "no-extraneous-class": { + "create": [Function], + "defaultOptions": [ + { + "allowConstructorOnly": false, + "allowEmpty": false, + "allowStaticOnly": false, + "allowWithDecorator": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow classes used as namespaces", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-extraneous-class", + }, + "messages": { + "empty": "Unexpected empty class.", + "onlyConstructor": "Unexpected class with only a constructor.", + "onlyStatic": "Unexpected class with only static properties.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConstructorOnly": { + "description": "Whether to allow extraneous classes that contain only a constructor.", + "type": "boolean", + }, + "allowEmpty": { + "description": "Whether to allow extraneous classes that have no body (i.e. are empty).", + "type": "boolean", + }, + "allowStaticOnly": { + "description": "Whether to allow extraneous classes that only contain static members.", + "type": "boolean", + }, + "allowWithDecorator": { + "description": "Whether to allow extraneous classes that include a decorator.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-floating-promises": { + "create": [Function], + "defaultOptions": [ + { + "ignoreIIFE": false, + "ignoreVoid": true, + }, + ], + "meta": { + "docs": { + "description": "Require Promise-like statements to be handled appropriately", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-floating-promises", + }, + "hasSuggestions": true, + "messages": { + "floating": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler.", + "floatingFixAwait": "Add await operator.", + "floatingFixVoid": "Add void operator to ignore.", + "floatingPromiseArray": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar.", + "floatingPromiseArrayVoid": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar, or explicitly marking the expression as ignored with the \`void\` operator.", + "floatingUselessRejectionHandler": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler. A rejection handler that is not a function will be ignored.", + "floatingUselessRejectionHandlerVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator. A rejection handler that is not a function will be ignored.", + "floatingVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreIIFE": { + "description": "Whether to ignore async IIFEs (Immediately Invoked Function Expressions).", + "type": "boolean", + }, + "ignoreVoid": { + "description": "Whether to ignore \`void\` expressions.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-for-in-array": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow iterating over an array with a for-in loop", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-for-in-array", + }, + "messages": { + "forInViolation": "For-in loops over arrays skips holes, returns indices as strings, and may visit the prototype chain or other enumerable properties. Use a more robust iteration method such as for-of or array.forEach instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-implied-eval": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow the use of \`eval()\`-like methods", + "extendsBaseRule": true, + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-implied-eval", + }, + "messages": { + "noFunctionConstructor": "Implied eval. Do not use the Function constructor to create functions.", + "noImpliedEvalError": "Implied eval. Consider passing a function.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-import-type-side-effects": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of top-level import type qualifier when an import only has specifiers with inline type qualifiers", + "url": "https://typescript-eslint.io/rules/no-import-type-side-effects", + }, + "fixable": "code", + "messages": { + "useTopLevelQualifier": "TypeScript will only remove the inline type specifiers which will leave behind a side effect import at runtime. Convert this to a top-level type qualifier to properly remove the entire import.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-inferrable-types": { + "create": [Function], + "defaultOptions": [ + { + "ignoreParameters": false, + "ignoreProperties": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow explicit type declarations for variables or parameters initialized to a number, string, or boolean", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-inferrable-types", + }, + "fixable": "code", + "messages": { + "noInferrableType": "Type {{type}} trivially inferred from a {{type}} literal, remove type annotation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreParameters": { + "type": "boolean", + }, + "ignoreProperties": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-invalid-this": { + "create": [Function], + "defaultOptions": [ + { + "capIsConstructor": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`this\` keywords outside of classes or class-like objects", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-invalid-this", + }, + "hasSuggestions": undefined, + "messages": { + "unexpectedThis": "Unexpected 'this'.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "capIsConstructor": { + "default": true, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-invalid-void-type": { + "create": [Function], + "defaultOptions": [ + { + "allowAsThisParameter": false, + "allowInGenericTypeArguments": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`void\` type outside of generic or return types", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-invalid-void-type", + }, + "messages": { + "invalidVoidForGeneric": "{{ generic }} may not have void as a type argument.", + "invalidVoidNotReturn": "void is only valid as a return type.", + "invalidVoidNotReturnOrGeneric": "void is only valid as a return type or generic type argument.", + "invalidVoidNotReturnOrThisParam": "void is only valid as return type or type of \`this\` parameter.", + "invalidVoidNotReturnOrThisParamOrGeneric": "void is only valid as a return type or generic type argument or the type of a \`this\` parameter.", + "invalidVoidUnionConstituent": "void is not valid as a constituent in a union type", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAsThisParameter": { + "type": "boolean", + }, + "allowInGenericTypeArguments": { + "oneOf": [ + { + "type": "boolean", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-loop-func": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow function declarations that contain unsafe references inside loop statements", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-loop-func", + }, + "hasSuggestions": undefined, + "messages": { + "unsafeRefs": "Function declared in a loop contains unsafe references to variable(s) {{ varNames }}.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-loss-of-precision": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow literal numbers that lose precision", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-loss-of-precision", + }, + "hasSuggestions": undefined, + "messages": { + "noLossOfPrecision": "This number literal will lose precision at runtime.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-magic-numbers": { + "create": [Function], + "defaultOptions": [ + { + "detectObjects": false, + "enforceConst": false, + "ignore": [], + "ignoreArrayIndexes": false, + "ignoreEnums": false, + "ignoreNumericLiteralTypes": false, + "ignoreReadonlyClassProperties": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow magic numbers", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-magic-numbers", + }, + "messages": { + "noMagic": "No magic number: {{raw}}.", + "useConst": "Number constants declarations must use 'const'.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "detectObjects": { + "default": false, + "type": "boolean", + }, + "enforceConst": { + "default": false, + "type": "boolean", + }, + "ignore": { + "items": { + "anyOf": [ + { + "type": "number", + }, + { + "pattern": "^[+-]?(?:0|[1-9][0-9]*)n$", + "type": "string", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + "ignoreArrayIndexes": { + "default": false, + "type": "boolean", + }, + "ignoreClassFieldInitialValues": { + "default": false, + "type": "boolean", + }, + "ignoreDefaultValues": { + "default": false, + "type": "boolean", + }, + "ignoreEnums": { + "type": "boolean", + }, + "ignoreNumericLiteralTypes": { + "type": "boolean", + }, + "ignoreReadonlyClassProperties": { + "type": "boolean", + }, + "ignoreTypeIndexes": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-meaningless-void-operator": { + "create": [Function], + "defaultOptions": [ + { + "checkNever": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the \`void\` operator except when used to discard a value", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-meaningless-void-operator", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "meaninglessVoidOperator": "void operator shouldn't be used on {{type}}; it should convey that a return value is being ignored", + "removeVoid": "Remove 'void'", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checkNever": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-misused-new": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce valid definition of \`new\` and \`constructor\`", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-misused-new", + }, + "messages": { + "errorMessageClass": "Class cannot have method named \`new\`.", + "errorMessageInterface": "Interfaces cannot be constructed, only classes.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-misused-promises": { + "create": [Function], + "defaultOptions": [ + { + "checksConditionals": true, + "checksSpreads": true, + "checksVoidReturn": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow Promises in places not designed to handle them", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-misused-promises", + }, + "messages": { + "conditional": "Expected non-Promise value in a boolean conditional.", + "spread": "Expected a non-Promise value to be spreaded in an object.", + "voidReturnArgument": "Promise returned in function argument where a void return was expected.", + "voidReturnAttribute": "Promise-returning function provided to attribute where a void return was expected.", + "voidReturnProperty": "Promise-returning function provided to property where a void return was expected.", + "voidReturnReturnValue": "Promise-returning function provided to return value where a void return was expected.", + "voidReturnVariable": "Promise-returning function provided to variable where a void return was expected.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checksConditionals": { + "type": "boolean", + }, + "checksSpreads": { + "type": "boolean", + }, + "checksVoidReturn": { + "oneOf": [ + { + "type": "boolean", + }, + { + "additionalProperties": false, + "properties": { + "arguments": { + "type": "boolean", + }, + "attributes": { + "type": "boolean", + }, + "properties": { + "type": "boolean", + }, + "returns": { + "type": "boolean", + }, + "variables": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-mixed-enums": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow enums from having both number and string members", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-mixed-enums", + }, + "messages": { + "mixed": "Mixing number and string enums can be confusing.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-namespace": { + "create": [Function], + "defaultOptions": [ + { + "allowDeclarations": false, + "allowDefinitionFiles": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow TypeScript namespaces", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-namespace", + }, + "messages": { + "moduleSyntaxIsPreferred": "ES2015 module syntax is preferred over namespaces.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDeclarations": { + "description": "Whether to allow \`declare\` with custom TypeScript namespaces.", + "type": "boolean", + }, + "allowDefinitionFiles": { + "description": "Whether to allow \`declare\` with custom TypeScript namespaces inside definition files.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-non-null-asserted-nullish-coalescing": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions in the left operand of a nullish coalescing operator", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-non-null-asserted-nullish-coalescing", + }, + "hasSuggestions": true, + "messages": { + "noNonNullAssertedNullishCoalescing": "The nullish coalescing operator is designed to handle undefined and null - using a non-null assertion is not needed.", + "suggestRemovingNonNull": "Remove the non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-non-null-asserted-optional-chain": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions after an optional chain expression", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-non-null-asserted-optional-chain", + }, + "hasSuggestions": true, + "messages": { + "noNonNullOptionalChain": "Optional chain expressions can return undefined by design - using a non-null assertion is unsafe and wrong.", + "suggestRemovingNonNull": "You should remove the non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions using the \`!\` postfix operator", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-non-null-assertion", + }, + "hasSuggestions": true, + "messages": { + "noNonNull": "Forbidden non-null assertion.", + "suggestOptionalChain": "Consider using the optional chain operator \`?.\` instead. This operator includes runtime checks, so it is safer than the compile-only non-null assertion operator.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-redeclare": { + "create": [Function], + "defaultOptions": [ + { + "builtinGlobals": true, + "ignoreDeclarationMerge": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow variable redeclaration", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-redeclare", + }, + "messages": { + "redeclared": "'{{id}}' is already defined.", + "redeclaredAsBuiltin": "'{{id}}' is already defined as a built-in global variable.", + "redeclaredBySyntax": "'{{id}}' is already defined by a variable declaration.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "builtinGlobals": { + "type": "boolean", + }, + "ignoreDeclarationMerge": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-redundant-type-constituents": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow members of unions and intersections that do nothing or override type information", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-redundant-type-constituents", + }, + "messages": { + "literalOverridden": "{{literal}} is overridden by {{primitive}} in this union type.", + "overridden": "'{{typeName}}' is overridden by other types in this {{container}} type.", + "overrides": "'{{typeName}}' overrides all other types in this {{container}} type.", + "primitiveOverridden": "{{primitive}} is overridden by the {{literal}} in this intersection type.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-require-imports": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow invocation of \`require()\`", + "url": "https://typescript-eslint.io/rules/no-require-imports", + }, + "messages": { + "noRequireImports": "A \`require()\` style import is forbidden.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "description": "Patterns of import paths to allow requiring from.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-restricted-imports": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow specified modules when loaded by \`import\`", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-restricted-imports", + }, + "fixable": undefined, + "messages": { + "everything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted.", + "everythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted. {{customMessage}}", + "importName": "'{{importName}}' import from '{{importSource}}' is restricted.", + "importNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted. {{customMessage}}", + "path": "'{{importSource}}' import is restricted from being used.", + "pathWithCustomMessage": "'{{importSource}}' import is restricted from being used. {{customMessage}}", + "patternAndEverything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern.", + "patternAndEverythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", + "patternAndEverythingWithRegexImportName": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used.", + "patternAndEverythingWithRegexImportNameAndCustomMessage": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used. {{customMessage}}", + "patternAndImportName": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern.", + "patternAndImportNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", + "patternWithCustomMessage": "'{{importSource}}' import is restricted from being used by a pattern. {{customMessage}}", + "patterns": "'{{importSource}}' import is restricted from being used by a pattern.", + }, + "schema": { + "anyOf": [ + { + "items": { + "anyOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "importNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "message": { + "minLength": 1, + "type": "string", + }, + "name": { + "type": "string", + }, + }, + "required": [ + "name", + ], + "type": "object", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + { + "additionalItems": false, + "items": [ + { + "additionalProperties": false, + "properties": { + "paths": { + "items": { + "anyOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "importNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "message": { + "minLength": 1, + "type": "string", + }, + "name": { + "type": "string", + }, + }, + "required": [ + "name", + ], + "type": "object", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + "patterns": { + "anyOf": [ + { + "items": { + "type": "string", + }, + "type": "array", + "uniqueItems": true, + }, + { + "items": { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "caseSensitive": { + "type": "boolean", + }, + "group": { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + "importNamePattern": { + "type": "string", + }, + "importNames": { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + "message": { + "minLength": 1, + "type": "string", + }, + }, + "required": [ + "group", + ], + "type": "object", + }, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "array", + }, + ], + }, + "type": "suggestion", + }, + }, + "no-shadow": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "builtinGlobals": false, + "hoist": "functions", + "ignoreFunctionTypeParameterNameValueShadow": true, + "ignoreOnInitialization": false, + "ignoreTypeValueShadow": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow variable declarations from shadowing variables declared in the outer scope", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-shadow", + }, + "messages": { + "noShadow": "'{{name}}' is already declared in the upper scope on line {{shadowedLine}} column {{shadowedColumn}}.", + "noShadowGlobal": "'{{name}}' is already a global variable.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "type": "string", + }, + "type": "array", + }, + "builtinGlobals": { + "type": "boolean", + }, + "hoist": { + "enum": [ + "all", + "functions", + "never", + ], + "type": "string", + }, + "ignoreFunctionTypeParameterNameValueShadow": { + "type": "boolean", + }, + "ignoreOnInitialization": { + "type": "boolean", + }, + "ignoreTypeValueShadow": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-this-alias": { + "create": [Function], + "defaultOptions": [ + { + "allowDestructuring": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow aliasing \`this\`", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-this-alias", + }, + "messages": { + "thisAssignment": "Unexpected aliasing of 'this' to local variable.", + "thisDestructure": "Unexpected aliasing of members of 'this' to local variables.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDestructuring": { + "description": "Whether to ignore destructurings, such as \`const { props, state } = this\`.", + "type": "boolean", + }, + "allowedNames": { + "description": "Names to ignore, such as ["self"] for \`const self = this;\`.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-throw-literal": { + "create": [Function], + "defaultOptions": [ + { + "allowThrowingAny": true, + "allowThrowingUnknown": true, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow throwing literals as exceptions", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-throw-literal", + }, + "messages": { + "object": "Expected an error object to be thrown.", + "undef": "Do not throw undefined.", + }, + "replacedBy": [ + "@typescript-eslint/only-throw-error", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowThrowingAny": { + "type": "boolean", + }, + "allowThrowingUnknown": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-type-alias": { + "create": [Function], + "defaultOptions": [ + { + "allowAliases": "never", + "allowCallbacks": "never", + "allowConditionalTypes": "never", + "allowConstructors": "never", + "allowGenerics": "never", + "allowLiterals": "never", + "allowMappedTypes": "never", + "allowTupleTypes": "never", + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow type aliases", + "url": "https://typescript-eslint.io/rules/no-type-alias", + }, + "messages": { + "noCompositionAlias": "{{typeName}} in {{compositionType}} types are not allowed.", + "noTypeAlias": "Type {{alias}} are not allowed.", + }, + "schema": [ + { + "$defs": { + "expandedOptions": { + "enum": [ + "always", + "never", + "in-unions", + "in-intersections", + "in-unions-and-intersections", + ], + "type": "string", + }, + "simpleOptions": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "allowAliases": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow direct one-to-one type aliases.", + }, + "allowCallbacks": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases for callbacks.", + }, + "allowConditionalTypes": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases for conditional types.", + }, + "allowConstructors": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases with constructors.", + }, + "allowGenerics": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases with generic types.", + }, + "allowLiterals": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with object literal types.", + }, + "allowMappedTypes": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with mapped types.", + }, + "allowTupleTypes": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with tuple types.", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-boolean-literal-compare": { + "create": [Function], + "defaultOptions": [ + { + "allowComparingNullableBooleansToFalse": true, + "allowComparingNullableBooleansToTrue": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow unnecessary equality comparisons against boolean literals", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-boolean-literal-compare", + }, + "fixable": "code", + "messages": { + "comparingNullableToFalse": "This expression unnecessarily compares a nullable boolean value to false instead of using the ?? operator to provide a default.", + "comparingNullableToTrueDirect": "This expression unnecessarily compares a nullable boolean value to true instead of using it directly.", + "comparingNullableToTrueNegated": "This expression unnecessarily compares a nullable boolean value to true instead of negating it.", + "direct": "This expression unnecessarily compares a boolean value to a boolean instead of using it directly.", + "negated": "This expression unnecessarily compares a boolean value to a boolean instead of negating it.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowComparingNullableBooleansToFalse": { + "description": "Whether to allow comparisons between nullable boolean variables and \`false\`.", + "type": "boolean", + }, + "allowComparingNullableBooleansToTrue": { + "description": "Whether to allow comparisons between nullable boolean variables and \`true\`.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-condition": { + "create": [Function], + "defaultOptions": [ + { + "allowConstantLoopConditions": false, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow conditionals where the type is always truthy or always falsy", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-condition", + }, + "fixable": "code", + "messages": { + "alwaysFalsy": "Unnecessary conditional, value is always falsy.", + "alwaysFalsyFunc": "This callback should return a conditional, but return is always falsy.", + "alwaysNullish": "Unnecessary conditional, left-hand side of \`??\` operator is always \`null\` or \`undefined\`.", + "alwaysTruthy": "Unnecessary conditional, value is always truthy.", + "alwaysTruthyFunc": "This callback should return a conditional, but return is always truthy.", + "literalBooleanExpression": "Unnecessary conditional, both sides of the expression are literal values.", + "never": "Unnecessary conditional, value is \`never\`.", + "neverNullish": "Unnecessary conditional, expected left-hand side of \`??\` operator to be possibly null or undefined.", + "neverOptionalChain": "Unnecessary optional chain on a non-nullish value.", + "noOverlapBooleanExpression": "Unnecessary conditional, the types have no overlap.", + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConstantLoopConditions": { + "description": "Whether to ignore constant loop conditions, such as \`while (true)\`.", + "type": "boolean", + }, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "description": "Whether to not error when running with a tsconfig that has strictNullChecks turned.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-qualifier": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary namespace qualifiers", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-qualifier", + }, + "fixable": "code", + "messages": { + "unnecessaryQualifier": "Qualifier is unnecessary since '{{ name }}' is in scope.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unnecessary-type-arguments": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow type arguments that are equal to the default", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-arguments", + }, + "fixable": "code", + "messages": { + "unnecessaryTypeParameter": "This is the default value for this type parameter, so it can be omitted.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unnecessary-type-assertion": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow type assertions that do not change the type of an expression", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-assertion", + }, + "fixable": "code", + "messages": { + "contextuallyUnnecessary": "This assertion is unnecessary since the receiver accepts the original type of the expression.", + "unnecessaryAssertion": "This assertion is unnecessary since it does not change the type of the expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "typesToIgnore": { + "description": "A list of type names to ignore.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-type-constraint": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary constraints on generic types", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-constraint", + }, + "hasSuggestions": true, + "messages": { + "removeUnnecessaryConstraint": "Remove the unnecessary \`{{constraint}}\` constraint.", + "unnecessaryConstraint": "Constraining the generic type \`{{name}}\` to \`{{constraint}}\` does nothing and is unnecessary.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unsafe-argument": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow calling a function with a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-argument", + }, + "messages": { + "unsafeArgument": "Unsafe argument of type \`{{sender}}\` assigned to a parameter of type \`{{receiver}}\`.", + "unsafeArraySpread": "Unsafe spread of an \`any\` array type.", + "unsafeSpread": "Unsafe spread of an \`any\` type.", + "unsafeTupleSpread": "Unsafe spread of a tuple type. The argument is of type \`{{sender}}\` and is assigned to a parameter of type \`{{receiver}}\`.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-assignment": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow assigning a value with type \`any\` to variables and properties", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-assignment", + }, + "messages": { + "anyAssignment": "Unsafe assignment of an \`any\` value.", + "anyAssignmentThis": "Unsafe assignment of an \`any\` value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + "unsafeArrayPattern": "Unsafe array destructuring of an \`any\` array value.", + "unsafeArrayPatternFromTuple": "Unsafe array destructuring of a tuple element with an \`any\` value.", + "unsafeArraySpread": "Unsafe spread of an \`any\` value in an array.", + "unsafeAssignment": "Unsafe assignment of type {{sender}} to a variable of type {{receiver}}.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-call": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow calling a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-call", + }, + "messages": { + "unsafeCall": "Unsafe call of an \`any\` typed value.", + "unsafeCallThis": "Unsafe call of an \`any\` typed value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + "unsafeNew": "Unsafe construction of an any type value.", + "unsafeTemplateTag": "Unsafe any typed template tag.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-declaration-merging": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unsafe declaration merging", + "recommended": "recommended", + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/no-unsafe-declaration-merging", + }, + "messages": { + "unsafeMerging": "Unsafe declaration merging between classes and interfaces.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-enum-comparison": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow comparing an enum value with a non-enum value", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-enum-comparison", + }, + "hasSuggestions": true, + "messages": { + "mismatchedCase": "The case statement does not have a shared enum type with the switch predicate.", + "mismatchedCondition": "The two values in this comparison do not have a shared enum type.", + "replaceValueWithEnum": "Replace with an enum value comparison.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unsafe-member-access": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow member access on a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-member-access", + }, + "messages": { + "unsafeComputedMemberAccess": "Computed name {{property}} resolves to an any value.", + "unsafeMemberExpression": "Unsafe member access {{property}} on an \`any\` value.", + "unsafeThisMemberExpression": "Unsafe member access {{property}} on an \`any\` value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-return": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow returning a value with type \`any\` from a function", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-return", + }, + "messages": { + "unsafeReturn": "Unsafe return of an \`{{type}}\` typed value.", + "unsafeReturnAssignment": "Unsafe return of type \`{{sender}}\` from function with return type \`{{receiver}}\`.", + "unsafeReturnThis": "Unsafe return of an \`{{type}}\` typed value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-unary-minus": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require unary negation to take a number", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-unary-minus", + }, + "messages": { + "unaryMinus": "Argument of unary negation should be assignable to number | bigint but is {{type}} instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unused-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowShortCircuit": false, + "allowTaggedTemplates": false, + "allowTernary": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow unused expressions", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-unused-expressions", + }, + "hasSuggestions": undefined, + "messages": { + "unusedExpression": "Expected an assignment or function call and instead saw an expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowShortCircuit": { + "default": false, + "type": "boolean", + }, + "allowTaggedTemplates": { + "default": false, + "type": "boolean", + }, + "allowTernary": { + "default": false, + "type": "boolean", + }, + "enforceForJSX": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unused-vars": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow unused variables", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-unused-vars", + }, + "messages": { + "unusedVar": "'{{varName}}' is {{action}} but never used{{additional}}.", + }, + "schema": [ + { + "oneOf": [ + { + "enum": [ + "all", + "local", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "args": { + "enum": [ + "all", + "after-used", + "none", + ], + "type": "string", + }, + "argsIgnorePattern": { + "type": "string", + }, + "caughtErrors": { + "enum": [ + "all", + "none", + ], + "type": "string", + }, + "caughtErrorsIgnorePattern": { + "type": "string", + }, + "destructuredArrayIgnorePattern": { + "type": "string", + }, + "ignoreRestSiblings": { + "type": "boolean", + }, + "vars": { + "enum": [ + "all", + "local", + ], + "type": "string", + }, + "varsIgnorePattern": { + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "problem", + }, + }, + "no-use-before-define": { + "create": [Function], + "defaultOptions": [ + { + "allowNamedExports": false, + "classes": true, + "enums": true, + "functions": true, + "ignoreTypeReferences": true, + "typedefs": true, + "variables": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow the use of variables before they are defined", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-use-before-define", + }, + "messages": { + "noUseBeforeDefine": "'{{name}}' was used before it was defined.", + }, + "schema": [ + { + "oneOf": [ + { + "enum": [ + "nofunc", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowNamedExports": { + "type": "boolean", + }, + "classes": { + "type": "boolean", + }, + "enums": { + "type": "boolean", + }, + "functions": { + "type": "boolean", + }, + "ignoreTypeReferences": { + "type": "boolean", + }, + "typedefs": { + "type": "boolean", + }, + "variables": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "problem", + }, + }, + "no-useless-constructor": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary constructors", + "extendsBaseRule": true, + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-useless-constructor", + }, + "hasSuggestions": undefined, + "messages": { + "noUselessConstructor": "Useless constructor.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-useless-empty-export": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow empty exports that don't change anything in a module file", + "url": "https://typescript-eslint.io/rules/no-useless-empty-export", + }, + "fixable": "code", + "hasSuggestions": false, + "messages": { + "uselessExport": "Empty export does nothing and can be removed.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-useless-template-literals": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary template literals", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-useless-template-literals", + }, + "fixable": "code", + "messages": { + "noUselessTemplateLiteral": "Template literal expression is unnecessary and can be simplified.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-var-requires": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow \`require\` statements except in import statements", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-var-requires", + }, + "messages": { + "noVarReqs": "Require statement not part of import statement.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "description": "Patterns of import paths to allow requiring from.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "non-nullable-type-assertion-style": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce non-null assertions over explicit type casts", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/non-nullable-type-assertion-style", + }, + "fixable": "code", + "messages": { + "preferNonNullAssertion": "Use a ! assertion to more succinctly remove null and undefined from the type.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "object-curly-spacing": { + "create": [Function], + "defaultOptions": [ + "never", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing inside braces", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/object-curly-spacing", + }, + "fixable": "whitespace", + "messages": { + "requireSpaceAfter": "A space is required after '{{token}}'.", + "requireSpaceBefore": "A space is required before '{{token}}'.", + "unexpectedSpaceAfter": "There should be no space after '{{token}}'.", + "unexpectedSpaceBefore": "There should be no space before '{{token}}'.", + }, + "replacedBy": [ + "@stylistic/ts/object-curly-spacing", + ], + "schema": [ + { + "enum": [ + "always", + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "arraysInObjects": { + "type": "boolean", + }, + "objectsInObjects": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "only-throw-error": { + "create": [Function], + "defaultOptions": [ + { + "allowThrowingAny": true, + "allowThrowingUnknown": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow throwing non-\`Error\` values as exceptions", + "extendsBaseRule": "no-throw-literal", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/only-throw-error", + }, + "messages": { + "object": "Expected an error object to be thrown.", + "undef": "Do not throw undefined.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowThrowingAny": { + "type": "boolean", + }, + "allowThrowingUnknown": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "padding-line-between-statements": { + "create": [Function], + "defaultOptions": [], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow padding lines between statements", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/padding-line-between-statements", + }, + "fixable": "whitespace", + "hasSuggestions": false, + "messages": { + "expectedBlankLine": "Expected blank line before this statement.", + "unexpectedBlankLine": "Unexpected blank line before this statement.", + }, + "replacedBy": [ + "@stylistic/ts/padding-line-between-statements", + ], + "schema": { + "$defs": { + "paddingType": { + "enum": [ + "any", + "never", + "always", + ], + "type": "string", + }, + "statementType": { + "anyOf": [ + { + "enum": [ + "*", + "block-like", + "exports", + "require", + "directive", + "expression", + "iife", + "multiline-block-like", + "multiline-expression", + "multiline-const", + "multiline-let", + "multiline-var", + "singleline-const", + "singleline-let", + "singleline-var", + "block", + "empty", + "function", + "break", + "case", + "class", + "const", + "continue", + "debugger", + "default", + "do", + "export", + "for", + "if", + "import", + "let", + "return", + "switch", + "throw", + "try", + "var", + "while", + "with", + "interface", + "type", + ], + "type": "string", + }, + { + "additionalItems": false, + "items": { + "enum": [ + "*", + "block-like", + "exports", + "require", + "directive", + "expression", + "iife", + "multiline-block-like", + "multiline-expression", + "multiline-const", + "multiline-let", + "multiline-var", + "singleline-const", + "singleline-let", + "singleline-var", + "block", + "empty", + "function", + "break", + "case", + "class", + "const", + "continue", + "debugger", + "default", + "do", + "export", + "for", + "if", + "import", + "let", + "return", + "switch", + "throw", + "try", + "var", + "while", + "with", + "interface", + "type", + ], + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "additionalItems": false, + "items": { + "additionalProperties": false, + "properties": { + "blankLine": { + "$ref": "#/$defs/paddingType", + }, + "next": { + "$ref": "#/$defs/statementType", + }, + "prev": { + "$ref": "#/$defs/statementType", + }, + }, + "required": [ + "blankLine", + "prev", + "next", + ], + "type": "object", + }, + "type": "array", + }, + "type": "layout", + }, + }, + "parameter-properties": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "prefer": "class-property", + }, + ], + "meta": { + "docs": { + "description": "Require or disallow parameter properties in class constructors", + "url": "https://typescript-eslint.io/rules/parameter-properties", + }, + "messages": { + "preferClassProperty": "Property {{parameter}} should be declared as a class property.", + "preferParameterProperty": "Property {{parameter}} should be declared as a parameter property.", + }, + "schema": [ + { + "$defs": { + "modifier": { + "enum": [ + "readonly", + "private", + "protected", + "public", + "private readonly", + "protected readonly", + "public readonly", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "$ref": "#/items/0/$defs/modifier", + }, + "type": "array", + }, + "prefer": { + "enum": [ + "class-property", + "parameter-property", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "prefer-as-const": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of \`as const\` over literal type", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/prefer-as-const", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "preferConstAssertion": "Expected a \`const\` instead of a literal type assertion.", + "variableConstAssertion": "Expected a \`const\` assertion instead of a literal type annotation.", + "variableSuggest": "You should use \`as const\` instead of type annotation.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-destructuring": { + "create": [Function], + "defaultOptions": [ + { + "AssignmentExpression": { + "array": true, + "object": true, + }, + "VariableDeclarator": { + "array": true, + "object": true, + }, + }, + {}, + ], + "meta": { + "docs": { + "description": "Require destructuring from arrays and/or objects", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-destructuring", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "preferDestructuring": "Use {{type}} destructuring.", + }, + "schema": [ + { + "oneOf": [ + { + "additionalProperties": false, + "properties": { + "AssignmentExpression": { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + "VariableDeclarator": { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + { + "properties": { + "enforceForDeclarationWithTypeAnnotation": { + "type": "boolean", + }, + "enforceForRenamedProperties": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-enum-initializers": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require each enum member value to be explicitly initialized", + "url": "https://typescript-eslint.io/rules/prefer-enum-initializers", + }, + "hasSuggestions": true, + "messages": { + "defineInitializer": "The value of the member '{{ name }}' should be explicitly defined.", + "defineInitializerSuggestion": "Can be fixed to {{ name }} = {{ suggested }}", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-find": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of Array.prototype.find() over Array.prototype.filter() followed by [0] when looking for a single result", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-find", + }, + "hasSuggestions": true, + "messages": { + "preferFind": "Prefer .find(...) instead of .filter(...)[0].", + "preferFindSuggestion": "Use .find(...) instead of .filter(...)[0].", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-for-of": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of \`for-of\` loop over the standard \`for\` loop where possible", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-for-of", + }, + "messages": { + "preferForOf": "Expected a \`for-of\` loop instead of a \`for\` loop with this simple iteration.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-function-type": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using function types instead of interfaces with call signatures", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-function-type", + }, + "fixable": "code", + "messages": { + "functionTypeOverCallableType": "{{ literalOrInterface }} only has a call signature, you should use a function type instead.", + "unexpectedThisOnFunctionOnlyInterface": "\`this\` refers to the function type '{{ interfaceName }}', did you intend to use a generic \`this\` parameter like \`(this: Self, ...) => Self\` instead?", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-includes": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce \`includes\` method over \`indexOf\` method", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-includes", + }, + "fixable": "code", + "messages": { + "preferIncludes": "Use 'includes()' method instead.", + "preferStringIncludes": "Use \`String#includes()\` method with a string instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-literal-enum-member": { + "create": [Function], + "defaultOptions": [ + { + "allowBitwiseExpressions": false, + }, + ], + "meta": { + "docs": { + "description": "Require all enum members to be literal values", + "recommended": "strict", + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/prefer-literal-enum-member", + }, + "messages": { + "notLiteral": "Explicit enum value must only be a literal value (string, number, boolean, etc).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowBitwiseExpressions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-namespace-keyword": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require using \`namespace\` keyword over \`module\` keyword to declare custom TypeScript modules", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-namespace-keyword", + }, + "fixable": "code", + "messages": { + "useNamespace": "Use 'namespace' instead of 'module' to declare custom TypeScript modules.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-nullish-coalescing": { + "create": [Function], + "defaultOptions": [ + { + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + "ignoreConditionalTests": false, + "ignoreMixedLogicalExpressions": false, + "ignorePrimitives": { + "bigint": false, + "boolean": false, + "number": false, + "string": false, + }, + "ignoreTernaryTests": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce using the nullish coalescing operator instead of logical assignments or chaining", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-nullish-coalescing", + }, + "hasSuggestions": true, + "messages": { + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + "preferNullishOverOr": "Prefer using nullish coalescing operator (\`??\`) instead of a logical or (\`||\`), as it is a safer operator.", + "preferNullishOverTernary": "Prefer using nullish coalescing operator (\`??\`) instead of a ternary expression, as it is simpler to read.", + "suggestNullish": "Fix to nullish coalescing operator (\`??\`).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "type": "boolean", + }, + "ignoreConditionalTests": { + "type": "boolean", + }, + "ignoreMixedLogicalExpressions": { + "type": "boolean", + }, + "ignorePrimitives": { + "oneOf": [ + { + "properties": { + "bigint": { + "type": "boolean", + }, + "boolean": { + "type": "boolean", + }, + "number": { + "type": "boolean", + }, + "string": { + "type": "boolean", + }, + }, + "type": "object", + }, + { + "enum": [ + true, + ], + "type": "boolean", + }, + ], + }, + "ignoreTernaryTests": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-optional-chain": { + "create": [Function], + "defaultOptions": [ + { + "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": false, + "checkAny": true, + "checkBigInt": true, + "checkBoolean": true, + "checkNumber": true, + "checkString": true, + "checkUnknown": true, + "requireNullish": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce using concise optional chain expressions instead of chained logical ands, negated logical ors, or empty objects", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-optional-chain", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "optionalChainSuggest": "Change to an optional chain.", + "preferOptionalChain": "Prefer using an optional chain expression instead, as it's more concise and easier to read.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": { + "description": "Allow autofixers that will change the return type of the expression. This option is considered unsafe as it may break the build.", + "type": "boolean", + }, + "checkAny": { + "description": "Check operands that are typed as \`any\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkBigInt": { + "description": "Check operands that are typed as \`bigint\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkBoolean": { + "description": "Check operands that are typed as \`boolean\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkNumber": { + "description": "Check operands that are typed as \`number\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkString": { + "description": "Check operands that are typed as \`string\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkUnknown": { + "description": "Check operands that are typed as \`unknown\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "requireNullish": { + "description": "Skip operands that are not typed with \`null\` and/or \`undefined\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-promise-reject-errors": { + "create": [Function], + "defaultOptions": [ + { + "allowEmptyReject": false, + }, + ], + "meta": { + "docs": { + "description": "Require using Error objects as Promise rejection reasons", + "extendsBaseRule": true, + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-promise-reject-errors", + }, + "messages": { + "rejectAnError": "Expected the Promise rejection reason to be an Error.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowEmptyReject": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-readonly": { + "create": [Function], + "defaultOptions": [ + { + "onlyInlineLambdas": false, + }, + ], + "meta": { + "docs": { + "description": "Require private members to be marked as \`readonly\` if they're never modified outside of the constructor", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-readonly", + }, + "fixable": "code", + "messages": { + "preferReadonly": "Member '{{name}}' is never reassigned; mark it as \`readonly\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "onlyInlineLambdas": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-readonly-parameter-types": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "checkParameterProperties": true, + "ignoreInferredTypes": false, + "treatMethodsAsReadonly": false, + }, + ], + "meta": { + "docs": { + "description": "Require function parameters to be typed as \`readonly\` to prevent accidental mutation of inputs", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-readonly-parameter-types", + }, + "messages": { + "shouldBeReadonly": "Parameter should be a read only type.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "oneOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "file", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + "path": { + "type": "string", + }, + }, + "required": [ + "from", + "name", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "lib", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "required": [ + "from", + "name", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "package", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + "package": { + "type": "string", + }, + }, + "required": [ + "from", + "name", + "package", + ], + "type": "object", + }, + ], + }, + "type": "array", + }, + "checkParameterProperties": { + "type": "boolean", + }, + "ignoreInferredTypes": { + "type": "boolean", + }, + "treatMethodsAsReadonly": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-reduce-type-parameter": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using type parameter when calling \`Array#reduce\` instead of casting", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-reduce-type-parameter", + }, + "fixable": "code", + "messages": { + "preferTypeParameter": "Unnecessary cast: Array#reduce accepts a type parameter for the default value.", + }, + "schema": [], + "type": "problem", + }, + }, + "prefer-regexp-exec": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce \`RegExp#exec\` over \`String#match\` if no global flag is provided", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-regexp-exec", + }, + "fixable": "code", + "messages": { + "regExpExecOverStringMatch": "Use the \`RegExp#exec()\` method instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-return-this-type": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce that \`this\` is used when only \`this\` type is returned", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-return-this-type", + }, + "fixable": "code", + "messages": { + "useThisType": "Use \`this\` type instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-string-starts-ends-with": { + "create": [Function], + "defaultOptions": [ + { + "allowSingleElementEquality": "never", + }, + ], + "meta": { + "docs": { + "description": "Enforce using \`String#startsWith\` and \`String#endsWith\` over other equivalent methods of checking substrings", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-string-starts-ends-with", + }, + "fixable": "code", + "messages": { + "preferEndsWith": "Use the 'String#endsWith' method instead.", + "preferStartsWith": "Use 'String#startsWith' method instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowSingleElementEquality": { + "description": "Whether to allow equality checks against the first or last element of a string.", + "enum": [ + "always", + "never", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-ts-expect-error": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using \`@ts-expect-error\` over \`@ts-ignore\`", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/prefer-ts-expect-error", + }, + "fixable": "code", + "messages": { + "preferExpectErrorComment": "Use "@ts-expect-error" to ensure an error is actually being suppressed.", + }, + "schema": [], + "type": "problem", + }, + }, + "promise-function-async": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowedPromiseNames": [], + "checkArrowFunctions": true, + "checkFunctionDeclarations": true, + "checkFunctionExpressions": true, + "checkMethodDeclarations": true, + }, + ], + "meta": { + "docs": { + "description": "Require any function or method that returns a Promise to be marked async", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/promise-function-async", + }, + "fixable": "code", + "messages": { + "missingAsync": "Functions that return promises must be async.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to consider \`any\` and \`unknown\` to be Promises.", + "type": "boolean", + }, + "allowedPromiseNames": { + "description": "Any extra names of classes or interfaces to be considered Promises.", + "items": { + "type": "string", + }, + "type": "array", + }, + "checkArrowFunctions": { + "type": "boolean", + }, + "checkFunctionDeclarations": { + "type": "boolean", + }, + "checkFunctionExpressions": { + "type": "boolean", + }, + "checkMethodDeclarations": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "quotes": { + "create": [Function], + "defaultOptions": [ + "double", + { + "allowTemplateLiterals": false, + "avoidEscape": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce the consistent use of either backticks, double, or single quotes", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/quotes", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "wrongQuotes": "Strings must use {{description}}.", + }, + "replacedBy": [ + "@stylistic/ts/quotes", + ], + "schema": [ + { + "enum": [ + "single", + "double", + "backtick", + ], + }, + { + "anyOf": [ + { + "enum": [ + "avoid-escape", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowTemplateLiterals": { + "type": "boolean", + }, + "avoidEscape": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "require-array-sort-compare": { + "create": [Function], + "defaultOptions": [ + { + "ignoreStringArrays": true, + }, + ], + "meta": { + "docs": { + "description": "Require \`Array#sort\` and \`Array#toSorted\` calls to always provide a \`compareFunction\`", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/require-array-sort-compare", + }, + "messages": { + "requireCompare": "Require 'compare' argument.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreStringArrays": { + "description": "Whether to ignore arrays in which all elements are strings.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "require-await": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow async functions which have no \`await\` expression", + "extendsBaseRule": true, + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/require-await", + }, + "messages": { + "missingAwait": "{{name}} has no 'await' expression.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "restrict-plus-operands": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowBoolean": true, + "allowNullish": true, + "allowNumberAndString": true, + "allowRegExp": true, + "skipCompoundAssignments": false, + }, + ], + "meta": { + "docs": { + "description": "Require both operands of addition to be the same type and be \`bigint\`, \`number\`, or \`string\`", + "recommended": { + "recommended": true, + "strict": [ + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + }, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/restrict-plus-operands", + }, + "messages": { + "bigintAndNumber": "Numeric '+' operations must either be both bigints or both numbers. Got \`{{left}}\` + \`{{right}}\`.", + "invalid": "Invalid operand for a '+' operation. Operands must each be a number or {{stringLike}}. Got \`{{type}}\`.", + "mismatched": "Operands of '+' operations must be a number or {{stringLike}}. Got \`{{left}}\` + \`{{right}}\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to allow \`any\` typed values.", + "type": "boolean", + }, + "allowBoolean": { + "description": "Whether to allow \`boolean\` typed values.", + "type": "boolean", + }, + "allowNullish": { + "description": "Whether to allow potentially \`null\` or \`undefined\` typed values.", + "type": "boolean", + }, + "allowNumberAndString": { + "description": "Whether to allow \`bigint\`/\`number\` typed values and \`string\` typed values to be added together.", + "type": "boolean", + }, + "allowRegExp": { + "description": "Whether to allow \`regexp\` typed values.", + "type": "boolean", + }, + "skipCompoundAssignments": { + "description": "Whether to skip compound assignments such as \`+=\`.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "restrict-template-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowBoolean": true, + "allowNullish": true, + "allowNumber": true, + "allowRegExp": true, + }, + ], + "meta": { + "docs": { + "description": "Enforce template literal expressions to be of \`string\` type", + "recommended": { + "recommended": true, + "strict": [ + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + }, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/restrict-template-expressions", + }, + "messages": { + "invalidType": "Invalid type "{{type}}" of template literal expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to allow \`any\` typed values in template expressions.", + "type": "boolean", + }, + "allowArray": { + "description": "Whether to allow \`array\` typed values in template expressions.", + "type": "boolean", + }, + "allowBoolean": { + "description": "Whether to allow \`boolean\` typed values in template expressions.", + "type": "boolean", + }, + "allowNever": { + "description": "Whether to allow \`never\` typed values in template expressions.", + "type": "boolean", + }, + "allowNullish": { + "description": "Whether to allow \`nullish\` typed values in template expressions.", + "type": "boolean", + }, + "allowNumber": { + "description": "Whether to allow \`number\` typed values in template expressions.", + "type": "boolean", + }, + "allowRegExp": { + "description": "Whether to allow \`regexp\` typed values in template expressions.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "return-await": { + "create": [Function], + "defaultOptions": [ + "in-try-catch", + ], + "meta": { + "docs": { + "description": "Enforce consistent returning of awaited values", + "extendsBaseRule": "no-return-await", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/return-await", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "disallowedPromiseAwait": "Returning an awaited promise is not allowed in this context.", + "nonPromiseAwait": "Returning an awaited value that is not a promise is not allowed.", + "requiredPromiseAwait": "Returning an awaited promise is required in this context.", + }, + "schema": [ + { + "enum": [ + "in-try-catch", + "always", + "never", + ], + "type": "string", + }, + ], + "type": "problem", + }, + }, + "semi": { + "create": [Function], + "defaultOptions": [ + "always", + { + "beforeStatementContinuationChars": "any", + "omitLastInOneLineBlock": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow semicolons instead of ASI", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/semi", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "extraSemi": "Extra semicolon.", + "missingSemi": "Missing semicolon.", + }, + "replacedBy": [ + "@stylistic/ts/semi", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "beforeStatementContinuationChars": { + "enum": [ + "always", + "any", + "never", + ], + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "always", + ], + }, + { + "additionalProperties": false, + "properties": { + "omitLastInOneLineBlock": { + "type": "boolean", + }, + "omitLastInOneLineClassBody": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "sort-type-constituents": { + "create": [Function], + "defaultOptions": [ + { + "checkIntersections": true, + "checkUnions": true, + "groupOrder": [ + "named", + "keyword", + "operator", + "literal", + "function", + "import", + "conditional", + "object", + "tuple", + "intersection", + "union", + "nullish", + ], + }, + ], + "meta": { + "docs": { + "description": "Enforce constituents of a type union/intersection to be sorted alphabetically", + "url": "https://typescript-eslint.io/rules/sort-type-constituents", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "notSorted": "{{type}} type constituents must be sorted.", + "notSortedNamed": "{{type}} type {{name}} constituents must be sorted.", + "suggestFix": "Sort constituents of type (removes all comments).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checkIntersections": { + "description": "Whether to check intersection types.", + "type": "boolean", + }, + "checkUnions": { + "description": "Whether to check union types.", + "type": "boolean", + }, + "groupOrder": { + "description": "Ordering of the groups.", + "items": { + "enum": [ + "conditional", + "function", + "import", + "intersection", + "keyword", + "nullish", + "literal", + "named", + "object", + "operator", + "tuple", + "union", + ], + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "space-before-blocks": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before blocks", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-before-blocks", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "missingSpace": "Missing space before opening brace.", + "unexpectedSpace": "Unexpected space before opening brace.", + }, + "replacedBy": [ + "@stylistic/ts/space-before-blocks", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "always", + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "classes": { + "enum": [ + "always", + "never", + "off", + ], + }, + "functions": { + "enum": [ + "always", + "never", + "off", + ], + }, + "keywords": { + "enum": [ + "always", + "never", + "off", + ], + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "space-before-function-paren": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before function parenthesis", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-before-function-paren", + }, + "fixable": "whitespace", + "messages": { + "missing": "Missing space before function parentheses.", + "unexpected": "Unexpected space before function parentheses.", + }, + "replacedBy": [ + "@stylistic/ts/space-before-function-paren", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "anonymous": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + "asyncArrow": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + "named": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "space-infix-ops": { + "create": [Function], + "defaultOptions": [ + { + "int32Hint": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require spacing around infix operators", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-infix-ops", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "missingSpace": "Operator '{{operator}}' must be spaced.", + }, + "replacedBy": [ + "@stylistic/ts/space-infix-ops", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "int32Hint": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "strict-boolean-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": false, + "allowNullableBoolean": false, + "allowNullableEnum": false, + "allowNullableNumber": false, + "allowNullableObject": true, + "allowNullableString": false, + "allowNumber": true, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + "allowString": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow certain types in boolean expressions", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/strict-boolean-expressions", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "conditionErrorAny": "Unexpected any value in conditional. An explicit comparison or type cast is required.", + "conditionErrorNullableBoolean": "Unexpected nullable boolean value in conditional. Please handle the nullish case explicitly.", + "conditionErrorNullableEnum": "Unexpected nullable enum value in conditional. Please handle the nullish/zero/NaN cases explicitly.", + "conditionErrorNullableNumber": "Unexpected nullable number value in conditional. Please handle the nullish/zero/NaN cases explicitly.", + "conditionErrorNullableObject": "Unexpected nullable object value in conditional. An explicit null check is required.", + "conditionErrorNullableString": "Unexpected nullable string value in conditional. Please handle the nullish/empty cases explicitly.", + "conditionErrorNullish": "Unexpected nullish value in conditional. The condition is always false.", + "conditionErrorNumber": "Unexpected number value in conditional. An explicit zero/NaN check is required.", + "conditionErrorObject": "Unexpected object value in conditional. The condition is always true.", + "conditionErrorOther": "Unexpected value in conditional. A boolean expression is required.", + "conditionErrorString": "Unexpected string value in conditional. An explicit empty string check is required.", + "conditionFixCastBoolean": "Explicitly cast value to a boolean (\`Boolean(value)\`)", + "conditionFixCompareEmptyString": "Change condition to check for empty string (\`value !== ""\`)", + "conditionFixCompareFalse": "Change condition to check if false (\`value === false\`)", + "conditionFixCompareNaN": "Change condition to check for NaN (\`!Number.isNaN(value)\`)", + "conditionFixCompareNullish": "Change condition to check for null/undefined (\`value != null\`)", + "conditionFixCompareStringLength": "Change condition to check string's length (\`value.length !== 0\`)", + "conditionFixCompareTrue": "Change condition to check if true (\`value === true\`)", + "conditionFixCompareZero": "Change condition to check for 0 (\`value !== 0\`)", + "conditionFixDefaultEmptyString": "Explicitly treat nullish value the same as an empty string (\`value ?? ""\`)", + "conditionFixDefaultFalse": "Explicitly treat nullish value the same as false (\`value ?? false\`)", + "conditionFixDefaultZero": "Explicitly treat nullish value the same as 0 (\`value ?? 0\`)", + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "type": "boolean", + }, + "allowNullableBoolean": { + "type": "boolean", + }, + "allowNullableEnum": { + "type": "boolean", + }, + "allowNullableNumber": { + "type": "boolean", + }, + "allowNullableObject": { + "type": "boolean", + }, + "allowNullableString": { + "type": "boolean", + }, + "allowNumber": { + "type": "boolean", + }, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "type": "boolean", + }, + "allowString": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "switch-exhaustiveness-check": { + "create": [Function], + "defaultOptions": [ + { + "allowDefaultCaseForExhaustiveSwitch": true, + "requireDefaultForNonUnion": false, + }, + ], + "meta": { + "docs": { + "description": "Require switch-case statements to be exhaustive", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/switch-exhaustiveness-check", + }, + "hasSuggestions": true, + "messages": { + "addMissingCases": "Add branches for missing cases.", + "dangerousDefaultCase": "The switch statement is exhaustive, so the default case is unnecessary.", + "switchIsNotExhaustive": "Switch is not exhaustive. Cases not matched: {{missingBranches}}", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDefaultCaseForExhaustiveSwitch": { + "description": "If 'true', allow 'default' cases on switch statements with exhaustive cases.", + "type": "boolean", + }, + "requireDefaultForNonUnion": { + "description": "If 'true', require a 'default' clause for switches on non-union types.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "triple-slash-reference": { + "create": [Function], + "defaultOptions": [ + { + "lib": "always", + "path": "never", + "types": "prefer-import", + }, + ], + "meta": { + "docs": { + "description": "Disallow certain triple slash directives in favor of ES6-style import declarations", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/triple-slash-reference", + }, + "messages": { + "tripleSlashReference": "Do not use a triple slash reference for {{module}}, use \`import\` style instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "lib": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + "path": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + "types": { + "enum": [ + "always", + "never", + "prefer-import", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "type-annotation-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require consistent spacing around type annotations", + "url": "https://typescript-eslint.io/rules/type-annotation-spacing", + }, + "fixable": "whitespace", + "messages": { + "expectedSpaceAfter": "Expected a space after the '{{type}}'.", + "expectedSpaceBefore": "Expected a space before the '{{type}}'.", + "unexpectedSpaceAfter": "Unexpected space after the '{{type}}'.", + "unexpectedSpaceBefore": "Unexpected space before the '{{type}}'.", + "unexpectedSpaceBetween": "Unexpected space between the '{{previousToken}}' and the '{{type}}'.", + }, + "replacedBy": [ + "@stylistic/ts/type-annotation-spacing", + ], + "schema": [ + { + "$defs": { + "spacingConfig": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "arrow": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "colon": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "parameter": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "property": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "returnType": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "variable": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "typedef": { + "create": [Function], + "defaultOptions": [ + { + "arrayDestructuring": false, + "arrowParameter": false, + "memberVariableDeclaration": false, + "objectDestructuring": false, + "parameter": false, + "propertyDeclaration": false, + "variableDeclaration": false, + "variableDeclarationIgnoreFunction": false, + }, + ], + "meta": { + "docs": { + "description": "Require type annotations in certain places", + "url": "https://typescript-eslint.io/rules/typedef", + }, + "messages": { + "expectedTypedef": "Expected a type annotation.", + "expectedTypedefNamed": "Expected {{name}} to have a type annotation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "arrayDestructuring": { + "type": "boolean", + }, + "arrowParameter": { + "type": "boolean", + }, + "memberVariableDeclaration": { + "type": "boolean", + }, + "objectDestructuring": { + "type": "boolean", + }, + "parameter": { + "type": "boolean", + }, + "propertyDeclaration": { + "type": "boolean", + }, + "variableDeclaration": { + "type": "boolean", + }, + "variableDeclarationIgnoreFunction": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "unbound-method": { + "create": [Function], + "defaultOptions": [ + { + "ignoreStatic": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce unbound methods are called with their expected scope", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/unbound-method", + }, + "messages": { + "unbound": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`.", + "unboundWithoutThisAnnotation": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`. +If your function does not access \`this\`, you can annotate it with \`this: void\`, or consider using an arrow function instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreStatic": { + "description": "Whether to skip checking whether \`static\` methods are correctly bound.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "unified-signatures": { + "create": [Function], + "defaultOptions": [ + { + "ignoreDifferentlyNamedParameters": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow two overloads that could be unified into one with a union or an optional/rest parameter", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/unified-signatures", + }, + "messages": { + "omittingRestParameter": "{{failureStringStart}} with a rest parameter.", + "omittingSingleParameter": "{{failureStringStart}} with an optional parameter.", + "singleParameterDifference": "{{failureStringStart}} taking \`{{type1}} | {{type2}}\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreDifferentlyNamedParameters": { + "description": "Whether two parameters with different names at the same index should be considered different even if their types are the same.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "use-unknown-in-catch-callback-variable": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce typing arguments in \`.catch()\` callbacks as \`unknown\`", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/use-unknown-in-catch-callback-variable", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "addUnknownRestTypeAnnotationSuggestion": "Add an explicit \`: [unknown]\` type annotation to the catch rest variable.", + "addUnknownTypeAnnotationSuggestion": "Add an explicit \`: unknown\` type annotation to the catch variable.", + "useUnknown": "Prefer the safe \`: unknown\` for a catch callback variable.", + "useUnknownArrayDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may not be iterable.", + "useUnknownObjectDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may be nullable, or may not have the expected shape.", + "useUnknownSpreadArgs": "Prefer the safe \`: unknown\` for a catch callback variable. The argument list may contain a handler that does not use \`unknown\` for the catch callback variable.", + "wrongRestTypeAnnotationSuggestion": "Change existing type annotation to \`: [unknown]\`.", + "wrongTypeAnnotationSuggestion": "Change existing type annotation to \`: unknown\`.", + }, + "schema": [], + "type": "suggestion", + }, + }, + }, + }, + }, + }, + { + "files": [ + "**/*.ts", + "**/*.tsx", + "**/*.mts", + "**/*.cts", + ], + "name": "typescript-eslint/eslint-recommended", + "rules": { + "constructor-super": "off", + "getter-return": "off", + "no-const-assign": "off", + "no-dupe-args": "off", + "no-dupe-class-members": "off", + "no-dupe-keys": "off", + "no-func-assign": "off", + "no-import-assign": "off", + "no-new-symbol": "off", + "no-obj-calls": "off", + "no-redeclare": "off", + "no-setter-return": "off", + "no-this-before-super": "off", + "no-undef": "off", + "no-unreachable": "off", + "no-unsafe-negation": "off", + "no-var": "error", + "prefer-const": "error", + "prefer-rest-params": "error", + "prefer-spread": "error", + }, + }, + { + "name": "typescript-eslint/strict-type-checked", + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": [ + "error", + { + "minimumDescriptionLength": 10, + }, + ], + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/restrict-template-expressions": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/unified-signatures": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-throw-literal": "off", + "no-unused-vars": "off", + "no-useless-constructor": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + { + "languageOptions": { + "parser": { + "meta": { + "name": "typescript-eslint/parser", + "version": "7.6.0", + }, + "parseForESLint": [Function], + }, + "sourceType": "module", + }, + "name": "typescript-eslint/base", + "plugins": { + "@typescript-eslint": { + "configs": { + "all": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/class-methods-use-this": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-return": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/consistent-type-exports": "error", + "@typescript-eslint/consistent-type-imports": "error", + "@typescript-eslint/default-param-last": "error", + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/explicit-function-return-type": "error", + "@typescript-eslint/explicit-member-accessibility": "error", + "@typescript-eslint/explicit-module-boundary-types": "error", + "@typescript-eslint/init-declarations": "error", + "@typescript-eslint/max-params": "error", + "@typescript-eslint/member-ordering": "error", + "@typescript-eslint/method-signature-style": "error", + "@typescript-eslint/naming-convention": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-dupe-class-members": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-import-type-side-effects": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/no-invalid-this": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loop-func": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-magic-numbers": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-redeclare": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-require-imports": "error", + "@typescript-eslint/no-restricted-imports": "error", + "@typescript-eslint/no-shadow": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-qualifier": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unsafe-unary-minus": "error", + "@typescript-eslint/no-unused-expressions": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-use-before-define": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-useless-empty-export": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/parameter-properties": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-destructuring": "error", + "@typescript-eslint/prefer-enum-initializers": "error", + "@typescript-eslint/prefer-find": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-readonly": "error", + "@typescript-eslint/prefer-readonly-parameter-types": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-regexp-exec": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/promise-function-async": "error", + "@typescript-eslint/require-array-sort-compare": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/return-await": "error", + "@typescript-eslint/sort-type-constituents": "error", + "@typescript-eslint/strict-boolean-expressions": "error", + "@typescript-eslint/switch-exhaustiveness-check": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/typedef": "error", + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/unified-signatures": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "class-methods-use-this": "off", + "consistent-return": "off", + "default-param-last": "off", + "dot-notation": "off", + "init-declarations": "off", + "max-params": "off", + "no-array-constructor": "off", + "no-dupe-class-members": "off", + "no-empty-function": "off", + "no-implied-eval": "off", + "no-invalid-this": "off", + "no-loop-func": "off", + "no-loss-of-precision": "off", + "no-magic-numbers": "off", + "no-redeclare": "off", + "no-restricted-imports": "off", + "no-return-await": "off", + "no-shadow": "off", + "no-throw-literal": "off", + "no-unused-expressions": "off", + "no-unused-vars": "off", + "no-use-before-define": "off", + "no-useless-constructor": "off", + "prefer-destructuring": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "base": { + "parser": "@typescript-eslint/parser", + "parserOptions": { + "sourceType": "module", + }, + "plugins": [ + "@typescript-eslint", + ], + }, + "disable-type-checked": { + "parserOptions": { + "program": null, + "project": false, + }, + "rules": { + "@typescript-eslint/await-thenable": "off", + "@typescript-eslint/consistent-return": "off", + "@typescript-eslint/consistent-type-exports": "off", + "@typescript-eslint/dot-notation": "off", + "@typescript-eslint/naming-convention": "off", + "@typescript-eslint/no-array-delete": "off", + "@typescript-eslint/no-base-to-string": "off", + "@typescript-eslint/no-confusing-void-expression": "off", + "@typescript-eslint/no-duplicate-type-constituents": "off", + "@typescript-eslint/no-floating-promises": "off", + "@typescript-eslint/no-for-in-array": "off", + "@typescript-eslint/no-implied-eval": "off", + "@typescript-eslint/no-meaningless-void-operator": "off", + "@typescript-eslint/no-misused-promises": "off", + "@typescript-eslint/no-mixed-enums": "off", + "@typescript-eslint/no-redundant-type-constituents": "off", + "@typescript-eslint/no-throw-literal": "off", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off", + "@typescript-eslint/no-unnecessary-condition": "off", + "@typescript-eslint/no-unnecessary-qualifier": "off", + "@typescript-eslint/no-unnecessary-type-arguments": "off", + "@typescript-eslint/no-unnecessary-type-assertion": "off", + "@typescript-eslint/no-unsafe-argument": "off", + "@typescript-eslint/no-unsafe-assignment": "off", + "@typescript-eslint/no-unsafe-call": "off", + "@typescript-eslint/no-unsafe-enum-comparison": "off", + "@typescript-eslint/no-unsafe-member-access": "off", + "@typescript-eslint/no-unsafe-return": "off", + "@typescript-eslint/no-unsafe-unary-minus": "off", + "@typescript-eslint/no-useless-template-literals": "off", + "@typescript-eslint/non-nullable-type-assertion-style": "off", + "@typescript-eslint/only-throw-error": "off", + "@typescript-eslint/prefer-destructuring": "off", + "@typescript-eslint/prefer-find": "off", + "@typescript-eslint/prefer-includes": "off", + "@typescript-eslint/prefer-nullish-coalescing": "off", + "@typescript-eslint/prefer-optional-chain": "off", + "@typescript-eslint/prefer-promise-reject-errors": "off", + "@typescript-eslint/prefer-readonly": "off", + "@typescript-eslint/prefer-readonly-parameter-types": "off", + "@typescript-eslint/prefer-reduce-type-parameter": "off", + "@typescript-eslint/prefer-regexp-exec": "off", + "@typescript-eslint/prefer-return-this-type": "off", + "@typescript-eslint/prefer-string-starts-ends-with": "off", + "@typescript-eslint/promise-function-async": "off", + "@typescript-eslint/require-array-sort-compare": "off", + "@typescript-eslint/require-await": "off", + "@typescript-eslint/restrict-plus-operands": "off", + "@typescript-eslint/restrict-template-expressions": "off", + "@typescript-eslint/return-await": "off", + "@typescript-eslint/strict-boolean-expressions": "off", + "@typescript-eslint/switch-exhaustiveness-check": "off", + "@typescript-eslint/unbound-method": "off", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "off", + }, + }, + "eslint-recommended": { + "overrides": [ + { + "files": [ + "*.ts", + "*.tsx", + "*.mts", + "*.cts", + ], + "rules": { + "constructor-super": "off", + "getter-return": "off", + "no-const-assign": "off", + "no-dupe-args": "off", + "no-dupe-class-members": "off", + "no-dupe-keys": "off", + "no-func-assign": "off", + "no-import-assign": "off", + "no-new-symbol": "off", + "no-obj-calls": "off", + "no-redeclare": "off", + "no-setter-return": "off", + "no-this-before-super": "off", + "no-undef": "off", + "no-unreachable": "off", + "no-unsafe-negation": "off", + "no-var": "error", + "prefer-const": "error", + "prefer-rest-params": "error", + "prefer-spread": "error", + }, + }, + ], + }, + "recommended": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/triple-slash-reference": "error", + "no-array-constructor": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + }, + }, + "recommended-requiring-type-checking": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "require-await": "off", + }, + }, + "recommended-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "require-await": "off", + }, + }, + "recommended-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/unbound-method": "error", + "no-implied-eval": "off", + "require-await": "off", + }, + }, + "strict": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/ban-ts-comment": [ + "error", + { + "minimumDescriptionLength": 10, + }, + ], + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unified-signatures": "error", + "no-array-constructor": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "no-useless-constructor": "off", + }, + }, + "strict-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": [ + "error", + { + "minimumDescriptionLength": 10, + }, + ], + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/restrict-template-expressions": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/unified-signatures": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-throw-literal": "off", + "no-unused-vars": "off", + "no-useless-constructor": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "strict-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/restrict-template-expressions": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "no-implied-eval": "off", + "no-throw-literal": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "stylistic": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "no-empty-function": "off", + }, + }, + "stylistic-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "dot-notation": "off", + "no-empty-function": "off", + }, + }, + "stylistic-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "dot-notation": "off", + }, + }, + }, + "meta": { + "name": "@typescript-eslint/eslint-plugin", + "version": "7.6.0", + }, + "rules": { + "adjacent-overload-signatures": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require that function overload signatures be consecutive", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/adjacent-overload-signatures", + }, + "messages": { + "adjacentSignature": "All {{name}} signatures should be adjacent.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "array-type": { + "create": [Function], + "defaultOptions": [ + { + "default": "array", + }, + ], + "meta": { + "docs": { + "description": "Require consistently using either \`T[]\` or \`Array\` for arrays", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/array-type", + }, + "fixable": "code", + "messages": { + "errorStringArray": "Array type using '{{className}}<{{type}}>' is forbidden. Use '{{readonlyPrefix}}{{type}}[]' instead.", + "errorStringArraySimple": "Array type using '{{className}}<{{type}}>' is forbidden for simple types. Use '{{readonlyPrefix}}{{type}}[]' instead.", + "errorStringGeneric": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden. Use '{{className}}<{{type}}>' instead.", + "errorStringGenericSimple": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden for non-simple types. Use '{{className}}<{{type}}>' instead.", + }, + "schema": [ + { + "$defs": { + "arrayOption": { + "enum": [ + "array", + "generic", + "array-simple", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "default": { + "$ref": "#/items/0/$defs/arrayOption", + "description": "The array type expected for mutable cases.", + }, + "readonly": { + "$ref": "#/items/0/$defs/arrayOption", + "description": "The array type expected for readonly cases. If omitted, the value for \`default\` will be used.", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "await-thenable": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow awaiting a value that is not a Thenable", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/await-thenable", + }, + "hasSuggestions": true, + "messages": { + "await": "Unexpected \`await\` of a non-Promise (non-"Thenable") value.", + "removeAwait": "Remove unnecessary \`await\`.", + }, + "schema": [], + "type": "problem", + }, + }, + "ban-ts-comment": { + "create": [Function], + "defaultOptions": [ + { + "minimumDescriptionLength": 3, + "ts-check": false, + "ts-expect-error": "allow-with-description", + "ts-ignore": true, + "ts-nocheck": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`@ts-\` comments or require descriptions after directives", + "recommended": { + "recommended": true, + "strict": [ + { + "minimumDescriptionLength": 10, + }, + ], + }, + "url": "https://typescript-eslint.io/rules/ban-ts-comment", + }, + "hasSuggestions": true, + "messages": { + "replaceTsIgnoreWithTsExpectError": "Replace "@ts-ignore" with "@ts-expect-error".", + "tsDirectiveComment": "Do not use "@ts-{{directive}}" because it alters compilation errors.", + "tsDirectiveCommentDescriptionNotMatchPattern": "The description for the "@ts-{{directive}}" directive must match the {{format}} format.", + "tsDirectiveCommentRequiresDescription": "Include a description after the "@ts-{{directive}}" directive to explain why the @ts-{{directive}} is necessary. The description must be {{minimumDescriptionLength}} characters or longer.", + "tsIgnoreInsteadOfExpectError": "Use "@ts-expect-error" instead of "@ts-ignore", as "@ts-ignore" will do nothing if the following line is error-free.", + }, + "schema": [ + { + "$defs": { + "directiveConfigSchema": { + "oneOf": [ + { + "default": true, + "type": "boolean", + }, + { + "enum": [ + "allow-with-description", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "descriptionFormat": { + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "minimumDescriptionLength": { + "default": 3, + "type": "number", + }, + "ts-check": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-expect-error": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-ignore": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-nocheck": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "ban-tslint-comment": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow \`// tslint:\` comments", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/ban-tslint-comment", + }, + "fixable": "code", + "messages": { + "commentDetected": "tslint comment detected: "{{ text }}"", + }, + "schema": [], + "type": "suggestion", + }, + }, + "ban-types": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow certain types", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/ban-types", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "bannedTypeMessage": "Don't use \`{{name}}\` as a type.{{customMessage}}", + "bannedTypeReplacement": "Replace \`{{name}}\` with \`{{replacement}}\`.", + }, + "schema": [ + { + "$defs": { + "banConfig": { + "oneOf": [ + { + "description": "Bans the type with the default message", + "type": "null", + }, + { + "description": "Un-bans the type (useful when paired with \`extendDefaults\`)", + "enum": [ + false, + ], + "type": "boolean", + }, + { + "description": "Bans the type with the default message", + "enum": [ + true, + ], + "type": "boolean", + }, + { + "description": "Bans the type with a custom message", + "type": "string", + }, + { + "additionalProperties": false, + "description": "Bans a type", + "properties": { + "fixWith": { + "description": "Type to autofix replace with. Note that autofixers can be applied automatically - so you need to be careful with this option.", + "type": "string", + }, + "message": { + "description": "Custom error message", + "type": "string", + }, + "suggest": { + "additionalItems": false, + "description": "Types to suggest replacing with.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "extendDefaults": { + "type": "boolean", + }, + "types": { + "additionalProperties": { + "$ref": "#/items/0/$defs/banConfig", + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "block-spacing": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow or enforce spaces inside of blocks after opening block and before closing block", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/block-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "extra": "Unexpected space(s) {{location}} '{{token}}'.", + "missing": "Requires a space {{location}} '{{token}}'.", + }, + "replacedBy": [ + "@stylistic/ts/block-spacing", + ], + "schema": [ + { + "enum": [ + "always", + "never", + ], + }, + ], + "type": "layout", + }, + }, + "brace-style": { + "create": [Function], + "defaultOptions": [ + "1tbs", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent brace style for blocks", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/brace-style", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "blockSameLine": "Statement inside of curly braces should be on next line.", + "nextLineClose": "Closing curly brace does not appear on the same line as the subsequent block.", + "nextLineOpen": "Opening curly brace does not appear on the same line as controlling statement.", + "sameLineClose": "Closing curly brace appears on the same line as the subsequent block.", + "sameLineOpen": "Opening curly brace appears on the same line as controlling statement.", + "singleLineClose": "Closing curly brace should be on the same line as opening curly brace or on the line after the previous block.", + }, + "replacedBy": [ + "@stylistic/ts/brace-style", + ], + "schema": [ + { + "enum": [ + "1tbs", + "stroustrup", + "allman", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowSingleLine": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "class-literal-property-style": { + "create": [Function], + "defaultOptions": [ + "fields", + ], + "meta": { + "docs": { + "description": "Enforce that literals on classes are exposed in a consistent style", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/class-literal-property-style", + }, + "hasSuggestions": true, + "messages": { + "preferFieldStyle": "Literals should be exposed using readonly fields.", + "preferFieldStyleSuggestion": "Replace the literals with readonly fields.", + "preferGetterStyle": "Literals should be exposed using getters.", + "preferGetterStyleSuggestion": "Replace the literals with getters.", + }, + "schema": [ + { + "enum": [ + "fields", + "getters", + ], + "type": "string", + }, + ], + "type": "problem", + }, + }, + "class-methods-use-this": { + "create": [Function], + "defaultOptions": [ + { + "enforceForClassFields": true, + "exceptMethods": [], + "ignoreClassesThatImplementAnInterface": false, + "ignoreOverrideMethods": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce that class methods utilize \`this\`", + "extendsBaseRule": true, + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/class-methods-use-this", + }, + "messages": { + "missingThis": "Expected 'this' to be used by class {{name}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "enforceForClassFields": { + "default": true, + "description": "Enforces that functions used as instance field initializers utilize \`this\`", + "type": "boolean", + }, + "exceptMethods": { + "description": "Allows specified method names to be ignored with this rule", + "items": { + "type": "string", + }, + "type": "array", + }, + "ignoreClassesThatImplementAnInterface": { + "description": "Ignore classes that specifically implement some interface", + "oneOf": [ + { + "description": "Ignore all classes that implement an interface", + "type": "boolean", + }, + { + "description": "Ignore only the public fields of classes that implement an interface", + "enum": [ + "public-fields", + ], + "type": "string", + }, + ], + }, + "ignoreOverrideMethods": { + "description": "Ignore members marked with the \`override\` modifier", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "comma-dangle": { + "create": [Function], + "defaultOptions": [ + "never", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow trailing commas", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/comma-dangle", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "missing": "Missing trailing comma.", + "unexpected": "Unexpected trailing comma.", + }, + "replacedBy": [ + "@stylistic/ts/comma-dangle", + ], + "schema": { + "$defs": { + "value": { + "enum": [ + "always-multiline", + "always", + "never", + "only-multiline", + ], + "type": "string", + }, + "valueWithIgnore": { + "enum": [ + "always-multiline", + "always", + "never", + "only-multiline", + "ignore", + ], + "type": "string", + }, + }, + "additionalItems": false, + "items": [ + { + "oneOf": [ + { + "$ref": "#/$defs/value", + }, + { + "additionalProperties": false, + "properties": { + "arrays": { + "$ref": "#/$defs/valueWithIgnore", + }, + "enums": { + "$ref": "#/$defs/valueWithIgnore", + }, + "exports": { + "$ref": "#/$defs/valueWithIgnore", + }, + "functions": { + "$ref": "#/$defs/valueWithIgnore", + }, + "generics": { + "$ref": "#/$defs/valueWithIgnore", + }, + "imports": { + "$ref": "#/$defs/valueWithIgnore", + }, + "objects": { + "$ref": "#/$defs/valueWithIgnore", + }, + "tuples": { + "$ref": "#/$defs/valueWithIgnore", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "array", + }, + "type": "layout", + }, + }, + "comma-spacing": { + "create": [Function], + "defaultOptions": [ + { + "after": true, + "before": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before and after commas", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/comma-spacing", + }, + "fixable": "whitespace", + "messages": { + "missing": "A space is required {{loc}} ','.", + "unexpected": "There should be no space {{loc}} ','.", + }, + "replacedBy": [ + "@stylistic/ts/comma-spacing", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "after": { + "default": true, + "type": "boolean", + }, + "before": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "consistent-generic-constructors": { + "create": [Function], + "defaultOptions": [ + "constructor", + ], + "meta": { + "docs": { + "description": "Enforce specifying generic type arguments on type annotation or constructor name of a constructor call", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-generic-constructors", + }, + "fixable": "code", + "messages": { + "preferConstructor": "The generic type arguments should be specified as part of the constructor type arguments.", + "preferTypeAnnotation": "The generic type arguments should be specified as part of the type annotation.", + }, + "schema": [ + { + "enum": [ + "type-annotation", + "constructor", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-indexed-object-style": { + "create": [Function], + "defaultOptions": [ + "record", + ], + "meta": { + "docs": { + "description": "Require or disallow the \`Record\` type", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-indexed-object-style", + }, + "fixable": "code", + "messages": { + "preferIndexSignature": "An index signature is preferred over a record.", + "preferRecord": "A record is preferred over an index signature.", + }, + "schema": [ + { + "enum": [ + "record", + "index-signature", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-return": { + "create": [Function], + "defaultOptions": [ + { + "treatUndefinedAsUnspecified": false, + }, + ], + "meta": { + "docs": { + "description": "Require \`return\` statements to either always or never specify values", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/consistent-return", + }, + "hasSuggestions": undefined, + "messages": { + "missingReturn": "Expected to return a value at the end of {{name}}.", + "missingReturnValue": "{{name}} expected a return value.", + "unexpectedReturnValue": "{{name}} expected no return value.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "treatUndefinedAsUnspecified": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-assertions": { + "create": [Function], + "defaultOptions": [ + { + "assertionStyle": "as", + "objectLiteralTypeAssertions": "allow", + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type assertions", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-type-assertions", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "angle-bracket": "Use '<{{cast}}>' instead of 'as {{cast}}'.", + "as": "Use 'as {{cast}}' instead of '<{{cast}}>'.", + "never": "Do not use any type assertions.", + "replaceObjectTypeAssertionWithAnnotation": "Use const x: {{cast}} = { ... } instead.", + "replaceObjectTypeAssertionWithSatisfies": "Use const x = { ... } satisfies {{cast}} instead.", + "unexpectedObjectTypeAssertion": "Always prefer const x: T = { ... }.", + }, + "schema": [ + { + "oneOf": [ + { + "additionalProperties": false, + "properties": { + "assertionStyle": { + "enum": [ + "never", + ], + "type": "string", + }, + }, + "required": [ + "assertionStyle", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "assertionStyle": { + "enum": [ + "as", + "angle-bracket", + ], + "type": "string", + }, + "objectLiteralTypeAssertions": { + "enum": [ + "allow", + "allow-as-parameter", + "never", + ], + "type": "string", + }, + }, + "required": [ + "assertionStyle", + ], + "type": "object", + }, + ], + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-definitions": { + "create": [Function], + "defaultOptions": [ + "interface", + ], + "meta": { + "docs": { + "description": "Enforce type definitions to consistently use either \`interface\` or \`type\`", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-type-definitions", + }, + "fixable": "code", + "messages": { + "interfaceOverType": "Use an \`interface\` instead of a \`type\`.", + "typeOverInterface": "Use a \`type\` instead of an \`interface\`.", + }, + "schema": [ + { + "enum": [ + "interface", + "type", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-exports": { + "create": [Function], + "defaultOptions": [ + { + "fixMixedExportsWithInlineTypeSpecifier": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type exports", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/consistent-type-exports", + }, + "fixable": "code", + "messages": { + "multipleExportsAreTypes": "Type exports {{exportNames}} are not values and should be exported using \`export type\`.", + "singleExportIsType": "Type export {{exportNames}} is not a value and should be exported using \`export type\`.", + "typeOverValue": "All exports in the declaration are only used as types. Use \`export type\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "fixMixedExportsWithInlineTypeSpecifier": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-imports": { + "create": [Function], + "defaultOptions": [ + { + "disallowTypeAnnotations": true, + "fixStyle": "separate-type-imports", + "prefer": "type-imports", + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type imports", + "url": "https://typescript-eslint.io/rules/consistent-type-imports", + }, + "fixable": "code", + "messages": { + "avoidImportType": "Use an \`import\` instead of an \`import type\`.", + "noImportTypeAnnotations": "\`import()\` type annotations are forbidden.", + "someImportsAreOnlyTypes": "Imports {{typeImports}} are only used as type.", + "typeOverValue": "All imports in the declaration are only used as types. Use \`import type\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "disallowTypeAnnotations": { + "type": "boolean", + }, + "fixStyle": { + "enum": [ + "separate-type-imports", + "inline-type-imports", + ], + "type": "string", + }, + "prefer": { + "enum": [ + "type-imports", + "no-type-imports", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "default-param-last": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce default parameters to be last", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/default-param-last", + }, + "messages": { + "shouldBeLast": "Default parameters should be last.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "dot-notation": { + "create": [Function], + "defaultOptions": [ + { + "allowIndexSignaturePropertyAccess": false, + "allowKeywords": true, + "allowPattern": "", + "allowPrivateClassPropertyAccess": false, + "allowProtectedClassPropertyAccess": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce dot notation whenever possible", + "extendsBaseRule": true, + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/dot-notation", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "useBrackets": ".{{key}} is a syntax error.", + "useDot": "[{{key}}] is better written in dot notation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowIndexSignaturePropertyAccess": { + "default": false, + "type": "boolean", + }, + "allowKeywords": { + "default": true, + "type": "boolean", + }, + "allowPattern": { + "default": "", + "type": "string", + }, + "allowPrivateClassPropertyAccess": { + "default": false, + "type": "boolean", + }, + "allowProtectedClassPropertyAccess": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "explicit-function-return-type": { + "create": [Function], + "defaultOptions": [ + { + "allowConciseArrowFunctionExpressionsStartingWithVoid": false, + "allowDirectConstAssertionInArrowFunctions": true, + "allowExpressions": false, + "allowFunctionsWithoutTypeParameters": false, + "allowHigherOrderFunctions": true, + "allowIIFEs": false, + "allowTypedFunctionExpressions": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Require explicit return types on functions and class methods", + "url": "https://typescript-eslint.io/rules/explicit-function-return-type", + }, + "messages": { + "missingReturnType": "Missing return type on function.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConciseArrowFunctionExpressionsStartingWithVoid": { + "description": "Whether to allow arrow functions that start with the \`void\` keyword.", + "type": "boolean", + }, + "allowDirectConstAssertionInArrowFunctions": { + "description": "Whether to ignore arrow functions immediately returning a \`as const\` value.", + "type": "boolean", + }, + "allowExpressions": { + "description": "Whether to ignore function expressions (functions which are not part of a declaration).", + "type": "boolean", + }, + "allowFunctionsWithoutTypeParameters": { + "description": "Whether to ignore functions that don't have generic type parameters.", + "type": "boolean", + }, + "allowHigherOrderFunctions": { + "description": "Whether to ignore functions immediately returning another function expression.", + "type": "boolean", + }, + "allowIIFEs": { + "description": "Whether to ignore immediately invoked function expressions (IIFEs).", + "type": "boolean", + }, + "allowTypedFunctionExpressions": { + "description": "Whether to ignore type annotations on the variable of function expressions.", + "type": "boolean", + }, + "allowedNames": { + "description": "An array of function/method names that will not have their arguments or return values checked.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "explicit-member-accessibility": { + "create": [Function], + "defaultOptions": [ + { + "accessibility": "explicit", + }, + ], + "meta": { + "docs": { + "description": "Require explicit accessibility modifiers on class properties and methods", + "url": "https://typescript-eslint.io/rules/explicit-member-accessibility", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "addExplicitAccessibility": "Add '{{ type }}' accessibility modifier", + "missingAccessibility": "Missing accessibility modifier on {{type}} {{name}}.", + "unwantedPublicAccessibility": "Public accessibility modifier on {{type}} {{name}}.", + }, + "schema": [ + { + "$defs": { + "accessibilityLevel": { + "oneOf": [ + { + "description": "Always require an accessor.", + "enum": [ + "explicit", + ], + "type": "string", + }, + { + "description": "Require an accessor except when public.", + "enum": [ + "no-public", + ], + "type": "string", + }, + { + "description": "Never check whether there is an accessor.", + "enum": [ + "off", + ], + "type": "string", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "accessibility": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "ignoredMethodNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "accessors": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "constructors": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "methods": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "parameterProperties": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "properties": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "explicit-module-boundary-types": { + "create": [Function], + "defaultOptions": [ + { + "allowArgumentsExplicitlyTypedAsAny": false, + "allowDirectConstAssertionInArrowFunctions": true, + "allowHigherOrderFunctions": true, + "allowTypedFunctionExpressions": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Require explicit return and argument types on exported functions' and classes' public class methods", + "url": "https://typescript-eslint.io/rules/explicit-module-boundary-types", + }, + "messages": { + "anyTypedArg": "Argument '{{name}}' should be typed with a non-any type.", + "anyTypedArgUnnamed": "{{type}} argument should be typed with a non-any type.", + "missingArgType": "Argument '{{name}}' should be typed.", + "missingArgTypeUnnamed": "{{type}} argument should be typed.", + "missingReturnType": "Missing return type on function.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowArgumentsExplicitlyTypedAsAny": { + "description": "Whether to ignore arguments that are explicitly typed as \`any\`.", + "type": "boolean", + }, + "allowDirectConstAssertionInArrowFunctions": { + "description": "Whether to ignore return type annotations on body-less arrow functions that return an \`as const\` type assertion. +You must still type the parameters of the function.", + "type": "boolean", + }, + "allowHigherOrderFunctions": { + "description": "Whether to ignore return type annotations on functions immediately returning another function expression. +You must still type the parameters of the function.", + "type": "boolean", + }, + "allowTypedFunctionExpressions": { + "description": "Whether to ignore type annotations on the variable of a function expression.", + "type": "boolean", + }, + "allowedNames": { + "description": "An array of function/method names that will not have their arguments or return values checked.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "func-call-spacing": { + "create": [Function], + "defaultOptions": [ + "never", + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow spacing between function identifiers and their invocations", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/func-call-spacing", + }, + "fixable": "whitespace", + "messages": { + "missing": "Missing space between function name and paren.", + "unexpectedNewline": "Unexpected newline between function name and paren.", + "unexpectedWhitespace": "Unexpected whitespace between function name and paren.", + }, + "replacedBy": [ + "@stylistic/ts/func-call-spacing", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "always", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowNewlines": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "indent": { + "create": [Function], + "defaultOptions": [ + 4, + { + "SwitchCase": 1, + "flatTernaryExpressions": false, + "ignoredNodes": [], + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent indentation", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/indent", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "wrongIndentation": "Expected indentation of {{expected}} but found {{actual}}.", + }, + "replacedBy": [ + "@stylistic/ts/indent", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "tab", + ], + }, + { + "minimum": 0, + "type": "integer", + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "ArrayExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "CallExpression": { + "additionalProperties": false, + "properties": { + "arguments": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "FunctionDeclaration": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + "parameters": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "FunctionExpression": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + "parameters": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "ImportDeclaration": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "MemberExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "off", + ], + }, + ], + }, + "ObjectExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "StaticBlock": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + }, + "type": "object", + }, + "SwitchCase": { + "default": 0, + "minimum": 0, + "type": "integer", + }, + "VariableDeclarator": { + "oneOf": [ + { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "const": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "let": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "var": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + ], + }, + "flatTernaryExpressions": { + "default": false, + "type": "boolean", + }, + "ignoreComments": { + "default": false, + "type": "boolean", + }, + "ignoredNodes": { + "items": { + "not": { + "pattern": ":exit$", + }, + "type": "string", + }, + "type": "array", + }, + "offsetTernaryExpressions": { + "default": false, + "type": "boolean", + }, + "outerIIFEBody": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "init-declarations": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "docs": { + "description": "Require or disallow initialization in variable declarations", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/init-declarations", + }, + "hasSuggestions": undefined, + "messages": { + "initialized": "Variable '{{idName}}' should be initialized on declaration.", + "notInitialized": "Variable '{{idName}}' should not be initialized on declaration.", + }, + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "always", + ], + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "ignoreForLoopInit": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "suggestion", + }, + }, + "key-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing between property names and type annotations in types and interfaces", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/key-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "extraKey": "Extra space after {{computed}}key '{{key}}'.", + "extraValue": "Extra space before value for {{computed}}key '{{key}}'.", + "missingKey": "Missing space after {{computed}}key '{{key}}'.", + "missingValue": "Missing space before value for {{computed}}key '{{key}}'.", + }, + "replacedBy": [ + "@stylistic/ts/key-spacing", + ], + "schema": [ + { + "anyOf": [ + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "align": { + "anyOf": [ + { + "enum": [ + "colon", + "value", + ], + }, + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + ], + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "multiLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "align": { + "anyOf": [ + { + "enum": [ + "colon", + "value", + ], + }, + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + ], + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + "singleLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "align": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + "multiLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + "singleLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "keyword-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before and after keywords", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/keyword-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "expectedAfter": "Expected space(s) after "{{value}}".", + "expectedBefore": "Expected space(s) before "{{value}}".", + "unexpectedAfter": "Unexpected space(s) after "{{value}}".", + "unexpectedBefore": "Unexpected space(s) before "{{value}}".", + }, + "replacedBy": [ + "@stylistic/ts/keyword-spacing", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "after": { + "default": true, + "type": "boolean", + }, + "before": { + "default": true, + "type": "boolean", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "abstract": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "as": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "async": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "await": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "boolean": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "break": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "byte": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "case": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "catch": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "char": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "class": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "const": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "continue": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "debugger": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "default": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "delete": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "do": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "double": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "else": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "enum": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "export": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "extends": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "false": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "final": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "finally": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "float": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "for": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "from": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "function": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "get": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "goto": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "if": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "implements": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "import": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "in": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "instanceof": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "int": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "interface": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "let": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "long": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "native": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "new": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "null": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "of": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "package": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "private": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "protected": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "public": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "return": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "set": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "short": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "static": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "super": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "switch": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "synchronized": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "this": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "throw": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "throws": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "transient": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "true": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "try": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "type": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "typeof": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "var": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "void": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "volatile": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "while": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "with": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "yield": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "lines-around-comment": { + "create": [Function], + "defaultOptions": [ + { + "beforeBlockComment": true, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require empty lines around comments", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/lines-around-comment", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "after": "Expected line after comment.", + "before": "Expected line before comment.", + }, + "replacedBy": [ + "@stylistic/ts/lines-around-comment", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "afterBlockComment": { + "default": false, + "type": "boolean", + }, + "afterLineComment": { + "default": false, + "type": "boolean", + }, + "allowArrayEnd": { + "type": "boolean", + }, + "allowArrayStart": { + "type": "boolean", + }, + "allowBlockEnd": { + "default": false, + "type": "boolean", + }, + "allowBlockStart": { + "default": false, + "type": "boolean", + }, + "allowClassEnd": { + "type": "boolean", + }, + "allowClassStart": { + "type": "boolean", + }, + "allowEnumEnd": { + "type": "boolean", + }, + "allowEnumStart": { + "type": "boolean", + }, + "allowInterfaceEnd": { + "type": "boolean", + }, + "allowInterfaceStart": { + "type": "boolean", + }, + "allowModuleEnd": { + "type": "boolean", + }, + "allowModuleStart": { + "type": "boolean", + }, + "allowObjectEnd": { + "type": "boolean", + }, + "allowObjectStart": { + "type": "boolean", + }, + "allowTypeEnd": { + "type": "boolean", + }, + "allowTypeStart": { + "type": "boolean", + }, + "applyDefaultIgnorePatterns": { + "type": "boolean", + }, + "beforeBlockComment": { + "default": true, + "type": "boolean", + }, + "beforeLineComment": { + "default": false, + "type": "boolean", + }, + "ignorePattern": { + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "lines-between-class-members": { + "create": [Function], + "defaultOptions": [ + "always", + { + "exceptAfterOverload": true, + "exceptAfterSingleLine": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow an empty line between class members", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/lines-between-class-members", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "always": "Expected blank line between class members.", + "never": "Unexpected blank line between class members.", + }, + "replacedBy": [ + "@stylistic/ts/lines-between-class-members", + ], + "schema": [ + { + "anyOf": [ + { + "additionalProperties": false, + "properties": { + "enforce": { + "items": { + "additionalProperties": false, + "properties": { + "blankLine": { + "enum": [ + "always", + "never", + ], + }, + "next": { + "enum": [ + "method", + "field", + "*", + ], + }, + "prev": { + "enum": [ + "method", + "field", + "*", + ], + }, + }, + "required": [ + "blankLine", + "prev", + "next", + ], + "type": "object", + }, + "minItems": 1, + "type": "array", + }, + }, + "required": [ + "enforce", + ], + "type": "object", + }, + { + "enum": [ + "always", + "never", + ], + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "exceptAfterOverload": { + "default": true, + "type": "boolean", + }, + "exceptAfterSingleLine": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "max-params": { + "create": [Function], + "defaultOptions": [ + { + "countVoidThis": false, + "max": 3, + }, + ], + "meta": { + "docs": { + "description": "Enforce a maximum number of parameters in function definitions", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/max-params", + }, + "messages": { + "exceed": "{{name}} has too many parameters ({{count}}). Maximum allowed is {{max}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "countVoidThis": { + "type": "boolean", + }, + "max": { + "minimum": 0, + "type": "integer", + }, + "maximum": { + "minimum": 0, + "type": "integer", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "member-delimiter-style": { + "create": [Function], + "defaultOptions": [ + { + "multiline": { + "delimiter": "semi", + "requireLast": true, + }, + "multilineDetection": "brackets", + "singleline": { + "delimiter": "semi", + "requireLast": false, + }, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require a specific member delimiter style for interfaces and type literals", + "url": "https://typescript-eslint.io/rules/member-delimiter-style", + }, + "fixable": "whitespace", + "messages": { + "expectedComma": "Expected a comma.", + "expectedSemi": "Expected a semicolon.", + "unexpectedComma": "Unexpected separator (,).", + "unexpectedSemi": "Unexpected separator (;).", + }, + "replacedBy": [ + "@stylistic/ts/member-delimiter-style", + ], + "schema": [ + { + "$defs": { + "delimiterConfig": { + "additionalProperties": false, + "properties": { + "multiline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/multiLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + "singleline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/singleLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + "multiLineOption": { + "enum": [ + "none", + "semi", + "comma", + ], + "type": "string", + }, + "singleLineOption": { + "enum": [ + "semi", + "comma", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "multiline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/multiLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + "multilineDetection": { + "enum": [ + "brackets", + "last-member", + ], + "type": "string", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "interface": { + "$ref": "#/items/0/$defs/delimiterConfig", + }, + "typeLiteral": { + "$ref": "#/items/0/$defs/delimiterConfig", + }, + }, + "type": "object", + }, + "singleline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/singleLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "member-ordering": { + "create": [Function], + "defaultOptions": [ + { + "default": { + "memberTypes": [ + "signature", + "call-signature", + "public-static-field", + "protected-static-field", + "private-static-field", + "#private-static-field", + "public-decorated-field", + "protected-decorated-field", + "private-decorated-field", + "public-instance-field", + "protected-instance-field", + "private-instance-field", + "#private-instance-field", + "public-abstract-field", + "protected-abstract-field", + "public-field", + "protected-field", + "private-field", + "#private-field", + "static-field", + "instance-field", + "abstract-field", + "decorated-field", + "field", + "static-initialization", + "public-constructor", + "protected-constructor", + "private-constructor", + "constructor", + "public-static-accessor", + "protected-static-accessor", + "private-static-accessor", + "#private-static-accessor", + "public-decorated-accessor", + "protected-decorated-accessor", + "private-decorated-accessor", + "public-instance-accessor", + "protected-instance-accessor", + "private-instance-accessor", + "#private-instance-accessor", + "public-abstract-accessor", + "protected-abstract-accessor", + "public-accessor", + "protected-accessor", + "private-accessor", + "#private-accessor", + "static-accessor", + "instance-accessor", + "abstract-accessor", + "decorated-accessor", + "accessor", + "public-static-get", + "protected-static-get", + "private-static-get", + "#private-static-get", + "public-decorated-get", + "protected-decorated-get", + "private-decorated-get", + "public-instance-get", + "protected-instance-get", + "private-instance-get", + "#private-instance-get", + "public-abstract-get", + "protected-abstract-get", + "public-get", + "protected-get", + "private-get", + "#private-get", + "static-get", + "instance-get", + "abstract-get", + "decorated-get", + "get", + "public-static-set", + "protected-static-set", + "private-static-set", + "#private-static-set", + "public-decorated-set", + "protected-decorated-set", + "private-decorated-set", + "public-instance-set", + "protected-instance-set", + "private-instance-set", + "#private-instance-set", + "public-abstract-set", + "protected-abstract-set", + "public-set", + "protected-set", + "private-set", + "#private-set", + "static-set", + "instance-set", + "abstract-set", + "decorated-set", + "set", + "public-static-method", + "protected-static-method", + "private-static-method", + "#private-static-method", + "public-decorated-method", + "protected-decorated-method", + "private-decorated-method", + "public-instance-method", + "protected-instance-method", + "private-instance-method", + "#private-instance-method", + "public-abstract-method", + "protected-abstract-method", + "public-method", + "protected-method", + "private-method", + "#private-method", + "static-method", + "instance-method", + "abstract-method", + "decorated-method", + "method", + ], + }, + }, + ], + "meta": { + "docs": { + "description": "Require a consistent member declaration order", + "url": "https://typescript-eslint.io/rules/member-ordering", + }, + "messages": { + "incorrectGroupOrder": "Member {{name}} should be declared before all {{rank}} definitions.", + "incorrectOrder": "Member {{member}} should be declared before member {{beforeMember}}.", + "incorrectRequiredMembersOrder": "Member {{member}} should be declared after all {{optionalOrRequired}} members.", + }, + "schema": [ + { + "$defs": { + "allItems": { + "enum": [ + "readonly-signature", + "signature", + "readonly-field", + "public-readonly-field", + "public-decorated-readonly-field", + "decorated-readonly-field", + "static-readonly-field", + "public-static-readonly-field", + "instance-readonly-field", + "public-instance-readonly-field", + "abstract-readonly-field", + "public-abstract-readonly-field", + "protected-readonly-field", + "protected-decorated-readonly-field", + "protected-static-readonly-field", + "protected-instance-readonly-field", + "protected-abstract-readonly-field", + "private-readonly-field", + "private-decorated-readonly-field", + "private-static-readonly-field", + "private-instance-readonly-field", + "#private-readonly-field", + "#private-static-readonly-field", + "#private-instance-readonly-field", + "field", + "public-field", + "public-decorated-field", + "decorated-field", + "static-field", + "public-static-field", + "instance-field", + "public-instance-field", + "abstract-field", + "public-abstract-field", + "protected-field", + "protected-decorated-field", + "protected-static-field", + "protected-instance-field", + "protected-abstract-field", + "private-field", + "private-decorated-field", + "private-static-field", + "private-instance-field", + "#private-field", + "#private-static-field", + "#private-instance-field", + "method", + "public-method", + "public-decorated-method", + "decorated-method", + "static-method", + "public-static-method", + "instance-method", + "public-instance-method", + "abstract-method", + "public-abstract-method", + "protected-method", + "protected-decorated-method", + "protected-static-method", + "protected-instance-method", + "protected-abstract-method", + "private-method", + "private-decorated-method", + "private-static-method", + "private-instance-method", + "#private-method", + "#private-static-method", + "#private-instance-method", + "call-signature", + "constructor", + "public-constructor", + "protected-constructor", + "private-constructor", + "accessor", + "public-accessor", + "public-decorated-accessor", + "decorated-accessor", + "static-accessor", + "public-static-accessor", + "instance-accessor", + "public-instance-accessor", + "abstract-accessor", + "public-abstract-accessor", + "protected-accessor", + "protected-decorated-accessor", + "protected-static-accessor", + "protected-instance-accessor", + "protected-abstract-accessor", + "private-accessor", + "private-decorated-accessor", + "private-static-accessor", + "private-instance-accessor", + "#private-accessor", + "#private-static-accessor", + "#private-instance-accessor", + "get", + "public-get", + "public-decorated-get", + "decorated-get", + "static-get", + "public-static-get", + "instance-get", + "public-instance-get", + "abstract-get", + "public-abstract-get", + "protected-get", + "protected-decorated-get", + "protected-static-get", + "protected-instance-get", + "protected-abstract-get", + "private-get", + "private-decorated-get", + "private-static-get", + "private-instance-get", + "#private-get", + "#private-static-get", + "#private-instance-get", + "set", + "public-set", + "public-decorated-set", + "decorated-set", + "static-set", + "public-static-set", + "instance-set", + "public-instance-set", + "abstract-set", + "public-abstract-set", + "protected-set", + "protected-decorated-set", + "protected-static-set", + "protected-instance-set", + "protected-abstract-set", + "private-set", + "private-decorated-set", + "private-static-set", + "private-instance-set", + "#private-set", + "#private-static-set", + "#private-instance-set", + "static-initialization", + "static-static-initialization", + "public-static-static-initialization", + "instance-static-initialization", + "public-instance-static-initialization", + "abstract-static-initialization", + "public-abstract-static-initialization", + "protected-static-static-initialization", + "protected-instance-static-initialization", + "protected-abstract-static-initialization", + "private-static-static-initialization", + "private-instance-static-initialization", + "#private-static-static-initialization", + "#private-instance-static-initialization", + ], + "type": "string", + }, + "baseConfig": { + "oneOf": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/allItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/allItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "additionalProperties": false, + "properties": { + "memberTypes": { + "oneOf": [ + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/allItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/allItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + }, + "optionalityOrder": { + "$ref": "#/items/0/$defs/optionalityOrderOptions", + }, + "order": { + "$ref": "#/items/0/$defs/orderOptions", + }, + }, + "type": "object", + }, + ], + }, + "optionalityOrderOptions": { + "enum": [ + "optional-first", + "required-first", + ], + "type": "string", + }, + "orderOptions": { + "enum": [ + "alphabetically", + "alphabetically-case-insensitive", + "as-written", + "natural", + "natural-case-insensitive", + ], + "type": "string", + }, + "typeItems": { + "enum": [ + "readonly-signature", + "signature", + "readonly-field", + "field", + "method", + "constructor", + ], + "type": "string", + }, + "typesConfig": { + "oneOf": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/typeItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/typeItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "additionalProperties": false, + "properties": { + "memberTypes": { + "oneOf": [ + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/typeItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/typeItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + }, + "optionalityOrder": { + "$ref": "#/items/0/$defs/optionalityOrderOptions", + }, + "order": { + "$ref": "#/items/0/$defs/orderOptions", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "classExpressions": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "classes": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "default": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "interfaces": { + "$ref": "#/items/0/$defs/typesConfig", + }, + "typeLiterals": { + "$ref": "#/items/0/$defs/typesConfig", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "method-signature-style": { + "create": [Function], + "defaultOptions": [ + "property", + ], + "meta": { + "docs": { + "description": "Enforce using a particular method signature syntax", + "url": "https://typescript-eslint.io/rules/method-signature-style", + }, + "fixable": "code", + "messages": { + "errorMethod": "Shorthand method signature is forbidden. Use a function property instead.", + "errorProperty": "Function property signature is forbidden. Use a method shorthand instead.", + }, + "schema": [ + { + "enum": [ + "property", + "method", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "naming-convention": { + "create": [Function], + "defaultOptions": [ + { + "format": [ + "camelCase", + ], + "leadingUnderscore": "allow", + "selector": "default", + "trailingUnderscore": "allow", + }, + { + "format": [ + "camelCase", + "PascalCase", + ], + "selector": "import", + }, + { + "format": [ + "camelCase", + "UPPER_CASE", + ], + "leadingUnderscore": "allow", + "selector": "variable", + "trailingUnderscore": "allow", + }, + { + "format": [ + "PascalCase", + ], + "selector": "typeLike", + }, + ], + "meta": { + "docs": { + "description": "Enforce naming conventions for everything across a codebase", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/naming-convention", + }, + "messages": { + "doesNotMatchFormat": "{{type}} name \`{{name}}\` must match one of the following formats: {{formats}}", + "doesNotMatchFormatTrimmed": "{{type}} name \`{{name}}\` trimmed as \`{{processedName}}\` must match one of the following formats: {{formats}}", + "missingAffix": "{{type}} name \`{{name}}\` must have one of the following {{position}}es: {{affixes}}", + "missingUnderscore": "{{type}} name \`{{name}}\` must have {{count}} {{position}} underscore(s).", + "satisfyCustom": "{{type}} name \`{{name}}\` must {{regexMatch}} the RegExp: {{regex}}", + "unexpectedUnderscore": "{{type}} name \`{{name}}\` must not have a {{position}} underscore.", + }, + "schema": { + "$defs": { + "formatOptionsConfig": { + "oneOf": [ + { + "additionalItems": false, + "items": { + "$ref": "#/$defs/predefinedFormats", + }, + "type": "array", + }, + { + "type": "null", + }, + ], + }, + "matchRegexConfig": { + "additionalProperties": false, + "properties": { + "match": { + "type": "boolean", + }, + "regex": { + "type": "string", + }, + }, + "required": [ + "match", + "regex", + ], + "type": "object", + }, + "predefinedFormats": { + "enum": [ + "camelCase", + "strictCamelCase", + "PascalCase", + "StrictPascalCase", + "snake_case", + "UPPER_CASE", + ], + "type": "string", + }, + "prefixSuffixConfig": { + "additionalItems": false, + "items": { + "minLength": 1, + "type": "string", + }, + "type": "array", + }, + "typeModifiers": { + "enum": [ + "boolean", + "string", + "number", + "function", + "array", + ], + "type": "string", + }, + "underscoreOptions": { + "enum": [ + "forbid", + "allow", + "require", + "requireDouble", + "allowDouble", + "allowSingleOrDouble", + ], + "type": "string", + }, + }, + "additionalItems": false, + "items": { + "oneOf": [ + { + "additionalProperties": false, + "description": "Multiple selectors in one config", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "readonly", + "static", + "public", + "protected", + "private", + "#private", + "abstract", + "destructured", + "global", + "exported", + "unused", + "requiresQuotes", + "override", + "async", + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "additionalItems": false, + "items": { + "enum": [ + "default", + "variableLike", + "memberLike", + "typeLike", + "method", + "property", + "accessor", + "variable", + "function", + "parameter", + "parameterProperty", + "classicAccessor", + "enumMember", + "classMethod", + "objectLiteralMethod", + "typeMethod", + "classProperty", + "objectLiteralProperty", + "typeProperty", + "autoAccessor", + "class", + "interface", + "typeAlias", + "enum", + "typeParameter", + "import", + ], + "type": "string", + }, + "type": "array", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'default'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "readonly", + "static", + "public", + "protected", + "private", + "#private", + "abstract", + "destructured", + "global", + "exported", + "unused", + "requiresQuotes", + "override", + "async", + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "default", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'variableLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "variableLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'variable'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "destructured", + "exported", + "global", + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "variable", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'function'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "global", + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "function", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'parameter'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "destructured", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "parameter", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'memberLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "memberLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'objectLiteralProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "objectLiteralProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "readonly", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'parameterProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "private", + "protected", + "public", + "readonly", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "parameterProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'property'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "property", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'objectLiteralMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "objectLiteralMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'method'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "method", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classicAccessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classicAccessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'autoAccessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "autoAccessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'accessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "accessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'enumMember'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "enumMember", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'class'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "class", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'interface'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "interface", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeAlias'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeAlias", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'enum'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "enum", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeParameter'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeParameter", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'import'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "import", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + ], + }, + "type": "array", + }, + "type": "suggestion", + }, + }, + "no-array-constructor": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow generic \`Array\` constructors", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-array-constructor", + }, + "fixable": "code", + "messages": { + "useLiteral": "The array literal notation [] is preferable.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-array-delete": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow using the \`delete\` operator on array values", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-array-delete", + }, + "hasSuggestions": true, + "messages": { + "noArrayDelete": "Using the \`delete\` operator with an array expression is unsafe.", + "useSplice": "Use \`array.splice()\` instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-base-to-string": { + "create": [Function], + "defaultOptions": [ + { + "ignoredTypeNames": [ + "Error", + "RegExp", + "URL", + "URLSearchParams", + ], + }, + ], + "meta": { + "docs": { + "description": "Require \`.toString()\` to only be called on objects which provide useful information when stringified", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-base-to-string", + }, + "messages": { + "baseToString": "'{{name}}' {{certainty}} evaluate to '[object Object]' when stringified.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoredTypeNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-confusing-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertion in locations that may be confusing", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-confusing-non-null-assertion", + }, + "hasSuggestions": true, + "messages": { + "confusingAssign": "Confusing combinations of non-null assertion and equal test like "a! = b", which looks very similar to not equal "a != b".", + "confusingEqual": "Confusing combinations of non-null assertion and equal test like "a! == b", which looks very similar to not equal "a !== b".", + "notNeedInAssign": "Unnecessary non-null assertion (!) in assignment left hand.", + "notNeedInEqualTest": "Unnecessary non-null assertion (!) in equal test.", + "wrapUpLeft": "Wrap up left hand to avoid putting non-null assertion "!" and "=" together.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-confusing-void-expression": { + "create": [Function], + "defaultOptions": [ + { + "ignoreArrowShorthand": false, + "ignoreVoidOperator": false, + }, + ], + "meta": { + "docs": { + "description": "Require expressions of type void to appear in statement position", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-confusing-void-expression", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "invalidVoidExpr": "Placing a void expression inside another expression is forbidden. Move it to its own statement instead.", + "invalidVoidExprArrow": "Returning a void expression from an arrow function shorthand is forbidden. Please add braces to the arrow function.", + "invalidVoidExprArrowWrapVoid": "Void expressions returned from an arrow function shorthand must be marked explicitly with the \`void\` operator.", + "invalidVoidExprReturn": "Returning a void expression from a function is forbidden. Please move it before the \`return\` statement.", + "invalidVoidExprReturnLast": "Returning a void expression from a function is forbidden. Please remove the \`return\` statement.", + "invalidVoidExprReturnWrapVoid": "Void expressions returned from a function must be marked explicitly with the \`void\` operator.", + "invalidVoidExprWrapVoid": "Void expressions used inside another expression must be moved to its own statement or marked explicitly with the \`void\` operator.", + "voidExprWrapVoid": "Mark with an explicit \`void\` operator.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreArrowShorthand": { + "type": "boolean", + }, + "ignoreVoidOperator": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-dupe-class-members": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow duplicate class members", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-dupe-class-members", + }, + "hasSuggestions": undefined, + "messages": { + "unexpected": "Duplicate name '{{name}}'.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-duplicate-enum-values": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow duplicate enum member values", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-duplicate-enum-values", + }, + "hasSuggestions": false, + "messages": { + "duplicateValue": "Duplicate enum member value {{value}}.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-duplicate-type-constituents": { + "create": [Function], + "defaultOptions": [ + { + "ignoreIntersections": false, + "ignoreUnions": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow duplicate constituents of union or intersection types", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-duplicate-type-constituents", + }, + "fixable": "code", + "messages": { + "duplicate": "{{type}} type constituent is duplicated with {{previous}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreIntersections": { + "type": "boolean", + }, + "ignoreUnions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-dynamic-delete": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow using the \`delete\` operator on computed key expressions", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-dynamic-delete", + }, + "fixable": "code", + "messages": { + "dynamicDelete": "Do not delete dynamically computed property keys.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-empty-function": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow empty functions", + "extendsBaseRule": true, + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-empty-function", + }, + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unexpected empty {{name}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "enum": [ + "functions", + "arrowFunctions", + "generatorFunctions", + "methods", + "generatorMethods", + "getters", + "setters", + "constructors", + "private-constructors", + "protected-constructors", + "asyncFunctions", + "asyncMethods", + "decoratedFunctions", + "overrideMethods", + ], + "type": "string", + }, + "type": "array", + "uniqueItems": true, + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-empty-interface": { + "create": [Function], + "defaultOptions": [ + { + "allowSingleExtends": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the declaration of empty interfaces", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-empty-interface", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "noEmpty": "An empty interface is equivalent to \`{}\`.", + "noEmptyWithSuper": "An interface declaring no members is equivalent to its supertype.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowSingleExtends": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-explicit-any": { + "create": [Function], + "defaultOptions": [ + { + "fixToUnknown": false, + "ignoreRestArgs": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the \`any\` type", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-explicit-any", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "suggestNever": "Use \`never\` instead, this is useful when instantiating generic type parameters that you don't need to know the type of.", + "suggestUnknown": "Use \`unknown\` instead, this will force you to explicitly, and safely assert the type is correct.", + "unexpectedAny": "Unexpected any. Specify a different type.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "fixToUnknown": { + "description": "Whether to enable auto-fixing in which the \`any\` type is converted to the \`unknown\` type.", + "type": "boolean", + }, + "ignoreRestArgs": { + "description": "Whether to ignore rest parameter arrays.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-extra-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow extra non-null assertions", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-extra-non-null-assertion", + }, + "fixable": "code", + "messages": { + "noExtraNonNullAssertion": "Forbidden extra non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-extra-parens": { + "create": [Function], + "defaultOptions": [ + "all", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow unnecessary parentheses", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-extra-parens", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unnecessary parentheses around expression.", + }, + "replacedBy": [ + "@stylistic/ts/no-extra-parens", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "functions", + ], + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "all", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowParensAfterCommentPattern": { + "type": "string", + }, + "conditionalAssign": { + "type": "boolean", + }, + "enforceForArrowConditionals": { + "type": "boolean", + }, + "enforceForFunctionPrototypeMethods": { + "type": "boolean", + }, + "enforceForNewInMemberExpressions": { + "type": "boolean", + }, + "enforceForSequenceExpressions": { + "type": "boolean", + }, + "ignoreJSX": { + "enum": [ + "none", + "all", + "single-line", + "multi-line", + ], + }, + "nestedBinaryExpressions": { + "type": "boolean", + }, + "returnAssign": { + "type": "boolean", + }, + "ternaryOperandBinaryExpressions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "no-extra-semi": { + "create": [Function], + "defaultOptions": [], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow unnecessary semicolons", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-extra-semi", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unnecessary semicolon.", + }, + "replacedBy": [ + "@stylistic/ts/no-extra-semi", + ], + "schema": [], + "type": "suggestion", + }, + }, + "no-extraneous-class": { + "create": [Function], + "defaultOptions": [ + { + "allowConstructorOnly": false, + "allowEmpty": false, + "allowStaticOnly": false, + "allowWithDecorator": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow classes used as namespaces", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-extraneous-class", + }, + "messages": { + "empty": "Unexpected empty class.", + "onlyConstructor": "Unexpected class with only a constructor.", + "onlyStatic": "Unexpected class with only static properties.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConstructorOnly": { + "description": "Whether to allow extraneous classes that contain only a constructor.", + "type": "boolean", + }, + "allowEmpty": { + "description": "Whether to allow extraneous classes that have no body (i.e. are empty).", + "type": "boolean", + }, + "allowStaticOnly": { + "description": "Whether to allow extraneous classes that only contain static members.", + "type": "boolean", + }, + "allowWithDecorator": { + "description": "Whether to allow extraneous classes that include a decorator.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-floating-promises": { + "create": [Function], + "defaultOptions": [ + { + "ignoreIIFE": false, + "ignoreVoid": true, + }, + ], + "meta": { + "docs": { + "description": "Require Promise-like statements to be handled appropriately", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-floating-promises", + }, + "hasSuggestions": true, + "messages": { + "floating": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler.", + "floatingFixAwait": "Add await operator.", + "floatingFixVoid": "Add void operator to ignore.", + "floatingPromiseArray": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar.", + "floatingPromiseArrayVoid": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar, or explicitly marking the expression as ignored with the \`void\` operator.", + "floatingUselessRejectionHandler": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler. A rejection handler that is not a function will be ignored.", + "floatingUselessRejectionHandlerVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator. A rejection handler that is not a function will be ignored.", + "floatingVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreIIFE": { + "description": "Whether to ignore async IIFEs (Immediately Invoked Function Expressions).", + "type": "boolean", + }, + "ignoreVoid": { + "description": "Whether to ignore \`void\` expressions.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-for-in-array": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow iterating over an array with a for-in loop", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-for-in-array", + }, + "messages": { + "forInViolation": "For-in loops over arrays skips holes, returns indices as strings, and may visit the prototype chain or other enumerable properties. Use a more robust iteration method such as for-of or array.forEach instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-implied-eval": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow the use of \`eval()\`-like methods", + "extendsBaseRule": true, + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-implied-eval", + }, + "messages": { + "noFunctionConstructor": "Implied eval. Do not use the Function constructor to create functions.", + "noImpliedEvalError": "Implied eval. Consider passing a function.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-import-type-side-effects": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of top-level import type qualifier when an import only has specifiers with inline type qualifiers", + "url": "https://typescript-eslint.io/rules/no-import-type-side-effects", + }, + "fixable": "code", + "messages": { + "useTopLevelQualifier": "TypeScript will only remove the inline type specifiers which will leave behind a side effect import at runtime. Convert this to a top-level type qualifier to properly remove the entire import.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-inferrable-types": { + "create": [Function], + "defaultOptions": [ + { + "ignoreParameters": false, + "ignoreProperties": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow explicit type declarations for variables or parameters initialized to a number, string, or boolean", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-inferrable-types", + }, + "fixable": "code", + "messages": { + "noInferrableType": "Type {{type}} trivially inferred from a {{type}} literal, remove type annotation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreParameters": { + "type": "boolean", + }, + "ignoreProperties": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-invalid-this": { + "create": [Function], + "defaultOptions": [ + { + "capIsConstructor": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`this\` keywords outside of classes or class-like objects", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-invalid-this", + }, + "hasSuggestions": undefined, + "messages": { + "unexpectedThis": "Unexpected 'this'.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "capIsConstructor": { + "default": true, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-invalid-void-type": { + "create": [Function], + "defaultOptions": [ + { + "allowAsThisParameter": false, + "allowInGenericTypeArguments": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`void\` type outside of generic or return types", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-invalid-void-type", + }, + "messages": { + "invalidVoidForGeneric": "{{ generic }} may not have void as a type argument.", + "invalidVoidNotReturn": "void is only valid as a return type.", + "invalidVoidNotReturnOrGeneric": "void is only valid as a return type or generic type argument.", + "invalidVoidNotReturnOrThisParam": "void is only valid as return type or type of \`this\` parameter.", + "invalidVoidNotReturnOrThisParamOrGeneric": "void is only valid as a return type or generic type argument or the type of a \`this\` parameter.", + "invalidVoidUnionConstituent": "void is not valid as a constituent in a union type", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAsThisParameter": { + "type": "boolean", + }, + "allowInGenericTypeArguments": { + "oneOf": [ + { + "type": "boolean", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-loop-func": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow function declarations that contain unsafe references inside loop statements", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-loop-func", + }, + "hasSuggestions": undefined, + "messages": { + "unsafeRefs": "Function declared in a loop contains unsafe references to variable(s) {{ varNames }}.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-loss-of-precision": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow literal numbers that lose precision", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-loss-of-precision", + }, + "hasSuggestions": undefined, + "messages": { + "noLossOfPrecision": "This number literal will lose precision at runtime.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-magic-numbers": { + "create": [Function], + "defaultOptions": [ + { + "detectObjects": false, + "enforceConst": false, + "ignore": [], + "ignoreArrayIndexes": false, + "ignoreEnums": false, + "ignoreNumericLiteralTypes": false, + "ignoreReadonlyClassProperties": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow magic numbers", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-magic-numbers", + }, + "messages": { + "noMagic": "No magic number: {{raw}}.", + "useConst": "Number constants declarations must use 'const'.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "detectObjects": { + "default": false, + "type": "boolean", + }, + "enforceConst": { + "default": false, + "type": "boolean", + }, + "ignore": { + "items": { + "anyOf": [ + { + "type": "number", + }, + { + "pattern": "^[+-]?(?:0|[1-9][0-9]*)n$", + "type": "string", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + "ignoreArrayIndexes": { + "default": false, + "type": "boolean", + }, + "ignoreClassFieldInitialValues": { + "default": false, + "type": "boolean", + }, + "ignoreDefaultValues": { + "default": false, + "type": "boolean", + }, + "ignoreEnums": { + "type": "boolean", + }, + "ignoreNumericLiteralTypes": { + "type": "boolean", + }, + "ignoreReadonlyClassProperties": { + "type": "boolean", + }, + "ignoreTypeIndexes": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-meaningless-void-operator": { + "create": [Function], + "defaultOptions": [ + { + "checkNever": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the \`void\` operator except when used to discard a value", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-meaningless-void-operator", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "meaninglessVoidOperator": "void operator shouldn't be used on {{type}}; it should convey that a return value is being ignored", + "removeVoid": "Remove 'void'", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checkNever": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-misused-new": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce valid definition of \`new\` and \`constructor\`", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-misused-new", + }, + "messages": { + "errorMessageClass": "Class cannot have method named \`new\`.", + "errorMessageInterface": "Interfaces cannot be constructed, only classes.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-misused-promises": { + "create": [Function], + "defaultOptions": [ + { + "checksConditionals": true, + "checksSpreads": true, + "checksVoidReturn": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow Promises in places not designed to handle them", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-misused-promises", + }, + "messages": { + "conditional": "Expected non-Promise value in a boolean conditional.", + "spread": "Expected a non-Promise value to be spreaded in an object.", + "voidReturnArgument": "Promise returned in function argument where a void return was expected.", + "voidReturnAttribute": "Promise-returning function provided to attribute where a void return was expected.", + "voidReturnProperty": "Promise-returning function provided to property where a void return was expected.", + "voidReturnReturnValue": "Promise-returning function provided to return value where a void return was expected.", + "voidReturnVariable": "Promise-returning function provided to variable where a void return was expected.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checksConditionals": { + "type": "boolean", + }, + "checksSpreads": { + "type": "boolean", + }, + "checksVoidReturn": { + "oneOf": [ + { + "type": "boolean", + }, + { + "additionalProperties": false, + "properties": { + "arguments": { + "type": "boolean", + }, + "attributes": { + "type": "boolean", + }, + "properties": { + "type": "boolean", + }, + "returns": { + "type": "boolean", + }, + "variables": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-mixed-enums": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow enums from having both number and string members", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-mixed-enums", + }, + "messages": { + "mixed": "Mixing number and string enums can be confusing.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-namespace": { + "create": [Function], + "defaultOptions": [ + { + "allowDeclarations": false, + "allowDefinitionFiles": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow TypeScript namespaces", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-namespace", + }, + "messages": { + "moduleSyntaxIsPreferred": "ES2015 module syntax is preferred over namespaces.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDeclarations": { + "description": "Whether to allow \`declare\` with custom TypeScript namespaces.", + "type": "boolean", + }, + "allowDefinitionFiles": { + "description": "Whether to allow \`declare\` with custom TypeScript namespaces inside definition files.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-non-null-asserted-nullish-coalescing": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions in the left operand of a nullish coalescing operator", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-non-null-asserted-nullish-coalescing", + }, + "hasSuggestions": true, + "messages": { + "noNonNullAssertedNullishCoalescing": "The nullish coalescing operator is designed to handle undefined and null - using a non-null assertion is not needed.", + "suggestRemovingNonNull": "Remove the non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-non-null-asserted-optional-chain": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions after an optional chain expression", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-non-null-asserted-optional-chain", + }, + "hasSuggestions": true, + "messages": { + "noNonNullOptionalChain": "Optional chain expressions can return undefined by design - using a non-null assertion is unsafe and wrong.", + "suggestRemovingNonNull": "You should remove the non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions using the \`!\` postfix operator", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-non-null-assertion", + }, + "hasSuggestions": true, + "messages": { + "noNonNull": "Forbidden non-null assertion.", + "suggestOptionalChain": "Consider using the optional chain operator \`?.\` instead. This operator includes runtime checks, so it is safer than the compile-only non-null assertion operator.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-redeclare": { + "create": [Function], + "defaultOptions": [ + { + "builtinGlobals": true, + "ignoreDeclarationMerge": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow variable redeclaration", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-redeclare", + }, + "messages": { + "redeclared": "'{{id}}' is already defined.", + "redeclaredAsBuiltin": "'{{id}}' is already defined as a built-in global variable.", + "redeclaredBySyntax": "'{{id}}' is already defined by a variable declaration.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "builtinGlobals": { + "type": "boolean", + }, + "ignoreDeclarationMerge": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-redundant-type-constituents": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow members of unions and intersections that do nothing or override type information", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-redundant-type-constituents", + }, + "messages": { + "literalOverridden": "{{literal}} is overridden by {{primitive}} in this union type.", + "overridden": "'{{typeName}}' is overridden by other types in this {{container}} type.", + "overrides": "'{{typeName}}' overrides all other types in this {{container}} type.", + "primitiveOverridden": "{{primitive}} is overridden by the {{literal}} in this intersection type.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-require-imports": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow invocation of \`require()\`", + "url": "https://typescript-eslint.io/rules/no-require-imports", + }, + "messages": { + "noRequireImports": "A \`require()\` style import is forbidden.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "description": "Patterns of import paths to allow requiring from.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-restricted-imports": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow specified modules when loaded by \`import\`", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-restricted-imports", + }, + "fixable": undefined, + "messages": { + "everything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted.", + "everythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted. {{customMessage}}", + "importName": "'{{importName}}' import from '{{importSource}}' is restricted.", + "importNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted. {{customMessage}}", + "path": "'{{importSource}}' import is restricted from being used.", + "pathWithCustomMessage": "'{{importSource}}' import is restricted from being used. {{customMessage}}", + "patternAndEverything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern.", + "patternAndEverythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", + "patternAndEverythingWithRegexImportName": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used.", + "patternAndEverythingWithRegexImportNameAndCustomMessage": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used. {{customMessage}}", + "patternAndImportName": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern.", + "patternAndImportNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", + "patternWithCustomMessage": "'{{importSource}}' import is restricted from being used by a pattern. {{customMessage}}", + "patterns": "'{{importSource}}' import is restricted from being used by a pattern.", + }, + "schema": { + "anyOf": [ + { + "items": { + "anyOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "importNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "message": { + "minLength": 1, + "type": "string", + }, + "name": { + "type": "string", + }, + }, + "required": [ + "name", + ], + "type": "object", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + { + "additionalItems": false, + "items": [ + { + "additionalProperties": false, + "properties": { + "paths": { + "items": { + "anyOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "importNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "message": { + "minLength": 1, + "type": "string", + }, + "name": { + "type": "string", + }, + }, + "required": [ + "name", + ], + "type": "object", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + "patterns": { + "anyOf": [ + { + "items": { + "type": "string", + }, + "type": "array", + "uniqueItems": true, + }, + { + "items": { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "caseSensitive": { + "type": "boolean", + }, + "group": { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + "importNamePattern": { + "type": "string", + }, + "importNames": { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + "message": { + "minLength": 1, + "type": "string", + }, + }, + "required": [ + "group", + ], + "type": "object", + }, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "array", + }, + ], + }, + "type": "suggestion", + }, + }, + "no-shadow": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "builtinGlobals": false, + "hoist": "functions", + "ignoreFunctionTypeParameterNameValueShadow": true, + "ignoreOnInitialization": false, + "ignoreTypeValueShadow": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow variable declarations from shadowing variables declared in the outer scope", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-shadow", + }, + "messages": { + "noShadow": "'{{name}}' is already declared in the upper scope on line {{shadowedLine}} column {{shadowedColumn}}.", + "noShadowGlobal": "'{{name}}' is already a global variable.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "type": "string", + }, + "type": "array", + }, + "builtinGlobals": { + "type": "boolean", + }, + "hoist": { + "enum": [ + "all", + "functions", + "never", + ], + "type": "string", + }, + "ignoreFunctionTypeParameterNameValueShadow": { + "type": "boolean", + }, + "ignoreOnInitialization": { + "type": "boolean", + }, + "ignoreTypeValueShadow": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-this-alias": { + "create": [Function], + "defaultOptions": [ + { + "allowDestructuring": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow aliasing \`this\`", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-this-alias", + }, + "messages": { + "thisAssignment": "Unexpected aliasing of 'this' to local variable.", + "thisDestructure": "Unexpected aliasing of members of 'this' to local variables.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDestructuring": { + "description": "Whether to ignore destructurings, such as \`const { props, state } = this\`.", + "type": "boolean", + }, + "allowedNames": { + "description": "Names to ignore, such as ["self"] for \`const self = this;\`.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-throw-literal": { + "create": [Function], + "defaultOptions": [ + { + "allowThrowingAny": true, + "allowThrowingUnknown": true, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow throwing literals as exceptions", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-throw-literal", + }, + "messages": { + "object": "Expected an error object to be thrown.", + "undef": "Do not throw undefined.", + }, + "replacedBy": [ + "@typescript-eslint/only-throw-error", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowThrowingAny": { + "type": "boolean", + }, + "allowThrowingUnknown": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-type-alias": { + "create": [Function], + "defaultOptions": [ + { + "allowAliases": "never", + "allowCallbacks": "never", + "allowConditionalTypes": "never", + "allowConstructors": "never", + "allowGenerics": "never", + "allowLiterals": "never", + "allowMappedTypes": "never", + "allowTupleTypes": "never", + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow type aliases", + "url": "https://typescript-eslint.io/rules/no-type-alias", + }, + "messages": { + "noCompositionAlias": "{{typeName}} in {{compositionType}} types are not allowed.", + "noTypeAlias": "Type {{alias}} are not allowed.", + }, + "schema": [ + { + "$defs": { + "expandedOptions": { + "enum": [ + "always", + "never", + "in-unions", + "in-intersections", + "in-unions-and-intersections", + ], + "type": "string", + }, + "simpleOptions": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "allowAliases": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow direct one-to-one type aliases.", + }, + "allowCallbacks": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases for callbacks.", + }, + "allowConditionalTypes": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases for conditional types.", + }, + "allowConstructors": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases with constructors.", + }, + "allowGenerics": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases with generic types.", + }, + "allowLiterals": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with object literal types.", + }, + "allowMappedTypes": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with mapped types.", + }, + "allowTupleTypes": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with tuple types.", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-boolean-literal-compare": { + "create": [Function], + "defaultOptions": [ + { + "allowComparingNullableBooleansToFalse": true, + "allowComparingNullableBooleansToTrue": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow unnecessary equality comparisons against boolean literals", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-boolean-literal-compare", + }, + "fixable": "code", + "messages": { + "comparingNullableToFalse": "This expression unnecessarily compares a nullable boolean value to false instead of using the ?? operator to provide a default.", + "comparingNullableToTrueDirect": "This expression unnecessarily compares a nullable boolean value to true instead of using it directly.", + "comparingNullableToTrueNegated": "This expression unnecessarily compares a nullable boolean value to true instead of negating it.", + "direct": "This expression unnecessarily compares a boolean value to a boolean instead of using it directly.", + "negated": "This expression unnecessarily compares a boolean value to a boolean instead of negating it.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowComparingNullableBooleansToFalse": { + "description": "Whether to allow comparisons between nullable boolean variables and \`false\`.", + "type": "boolean", + }, + "allowComparingNullableBooleansToTrue": { + "description": "Whether to allow comparisons between nullable boolean variables and \`true\`.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-condition": { + "create": [Function], + "defaultOptions": [ + { + "allowConstantLoopConditions": false, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow conditionals where the type is always truthy or always falsy", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-condition", + }, + "fixable": "code", + "messages": { + "alwaysFalsy": "Unnecessary conditional, value is always falsy.", + "alwaysFalsyFunc": "This callback should return a conditional, but return is always falsy.", + "alwaysNullish": "Unnecessary conditional, left-hand side of \`??\` operator is always \`null\` or \`undefined\`.", + "alwaysTruthy": "Unnecessary conditional, value is always truthy.", + "alwaysTruthyFunc": "This callback should return a conditional, but return is always truthy.", + "literalBooleanExpression": "Unnecessary conditional, both sides of the expression are literal values.", + "never": "Unnecessary conditional, value is \`never\`.", + "neverNullish": "Unnecessary conditional, expected left-hand side of \`??\` operator to be possibly null or undefined.", + "neverOptionalChain": "Unnecessary optional chain on a non-nullish value.", + "noOverlapBooleanExpression": "Unnecessary conditional, the types have no overlap.", + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConstantLoopConditions": { + "description": "Whether to ignore constant loop conditions, such as \`while (true)\`.", + "type": "boolean", + }, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "description": "Whether to not error when running with a tsconfig that has strictNullChecks turned.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-qualifier": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary namespace qualifiers", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-qualifier", + }, + "fixable": "code", + "messages": { + "unnecessaryQualifier": "Qualifier is unnecessary since '{{ name }}' is in scope.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unnecessary-type-arguments": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow type arguments that are equal to the default", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-arguments", + }, + "fixable": "code", + "messages": { + "unnecessaryTypeParameter": "This is the default value for this type parameter, so it can be omitted.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unnecessary-type-assertion": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow type assertions that do not change the type of an expression", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-assertion", + }, + "fixable": "code", + "messages": { + "contextuallyUnnecessary": "This assertion is unnecessary since the receiver accepts the original type of the expression.", + "unnecessaryAssertion": "This assertion is unnecessary since it does not change the type of the expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "typesToIgnore": { + "description": "A list of type names to ignore.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-type-constraint": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary constraints on generic types", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-constraint", + }, + "hasSuggestions": true, + "messages": { + "removeUnnecessaryConstraint": "Remove the unnecessary \`{{constraint}}\` constraint.", + "unnecessaryConstraint": "Constraining the generic type \`{{name}}\` to \`{{constraint}}\` does nothing and is unnecessary.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unsafe-argument": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow calling a function with a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-argument", + }, + "messages": { + "unsafeArgument": "Unsafe argument of type \`{{sender}}\` assigned to a parameter of type \`{{receiver}}\`.", + "unsafeArraySpread": "Unsafe spread of an \`any\` array type.", + "unsafeSpread": "Unsafe spread of an \`any\` type.", + "unsafeTupleSpread": "Unsafe spread of a tuple type. The argument is of type \`{{sender}}\` and is assigned to a parameter of type \`{{receiver}}\`.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-assignment": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow assigning a value with type \`any\` to variables and properties", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-assignment", + }, + "messages": { + "anyAssignment": "Unsafe assignment of an \`any\` value.", + "anyAssignmentThis": "Unsafe assignment of an \`any\` value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + "unsafeArrayPattern": "Unsafe array destructuring of an \`any\` array value.", + "unsafeArrayPatternFromTuple": "Unsafe array destructuring of a tuple element with an \`any\` value.", + "unsafeArraySpread": "Unsafe spread of an \`any\` value in an array.", + "unsafeAssignment": "Unsafe assignment of type {{sender}} to a variable of type {{receiver}}.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-call": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow calling a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-call", + }, + "messages": { + "unsafeCall": "Unsafe call of an \`any\` typed value.", + "unsafeCallThis": "Unsafe call of an \`any\` typed value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + "unsafeNew": "Unsafe construction of an any type value.", + "unsafeTemplateTag": "Unsafe any typed template tag.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-declaration-merging": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unsafe declaration merging", + "recommended": "recommended", + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/no-unsafe-declaration-merging", + }, + "messages": { + "unsafeMerging": "Unsafe declaration merging between classes and interfaces.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-enum-comparison": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow comparing an enum value with a non-enum value", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-enum-comparison", + }, + "hasSuggestions": true, + "messages": { + "mismatchedCase": "The case statement does not have a shared enum type with the switch predicate.", + "mismatchedCondition": "The two values in this comparison do not have a shared enum type.", + "replaceValueWithEnum": "Replace with an enum value comparison.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unsafe-member-access": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow member access on a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-member-access", + }, + "messages": { + "unsafeComputedMemberAccess": "Computed name {{property}} resolves to an any value.", + "unsafeMemberExpression": "Unsafe member access {{property}} on an \`any\` value.", + "unsafeThisMemberExpression": "Unsafe member access {{property}} on an \`any\` value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-return": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow returning a value with type \`any\` from a function", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-return", + }, + "messages": { + "unsafeReturn": "Unsafe return of an \`{{type}}\` typed value.", + "unsafeReturnAssignment": "Unsafe return of type \`{{sender}}\` from function with return type \`{{receiver}}\`.", + "unsafeReturnThis": "Unsafe return of an \`{{type}}\` typed value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-unary-minus": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require unary negation to take a number", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-unary-minus", + }, + "messages": { + "unaryMinus": "Argument of unary negation should be assignable to number | bigint but is {{type}} instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unused-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowShortCircuit": false, + "allowTaggedTemplates": false, + "allowTernary": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow unused expressions", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-unused-expressions", + }, + "hasSuggestions": undefined, + "messages": { + "unusedExpression": "Expected an assignment or function call and instead saw an expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowShortCircuit": { + "default": false, + "type": "boolean", + }, + "allowTaggedTemplates": { + "default": false, + "type": "boolean", + }, + "allowTernary": { + "default": false, + "type": "boolean", + }, + "enforceForJSX": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unused-vars": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow unused variables", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-unused-vars", + }, + "messages": { + "unusedVar": "'{{varName}}' is {{action}} but never used{{additional}}.", + }, + "schema": [ + { + "oneOf": [ + { + "enum": [ + "all", + "local", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "args": { + "enum": [ + "all", + "after-used", + "none", + ], + "type": "string", + }, + "argsIgnorePattern": { + "type": "string", + }, + "caughtErrors": { + "enum": [ + "all", + "none", + ], + "type": "string", + }, + "caughtErrorsIgnorePattern": { + "type": "string", + }, + "destructuredArrayIgnorePattern": { + "type": "string", + }, + "ignoreRestSiblings": { + "type": "boolean", + }, + "vars": { + "enum": [ + "all", + "local", + ], + "type": "string", + }, + "varsIgnorePattern": { + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "problem", + }, + }, + "no-use-before-define": { + "create": [Function], + "defaultOptions": [ + { + "allowNamedExports": false, + "classes": true, + "enums": true, + "functions": true, + "ignoreTypeReferences": true, + "typedefs": true, + "variables": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow the use of variables before they are defined", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-use-before-define", + }, + "messages": { + "noUseBeforeDefine": "'{{name}}' was used before it was defined.", + }, + "schema": [ + { + "oneOf": [ + { + "enum": [ + "nofunc", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowNamedExports": { + "type": "boolean", + }, + "classes": { + "type": "boolean", + }, + "enums": { + "type": "boolean", + }, + "functions": { + "type": "boolean", + }, + "ignoreTypeReferences": { + "type": "boolean", + }, + "typedefs": { + "type": "boolean", + }, + "variables": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "problem", + }, + }, + "no-useless-constructor": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary constructors", + "extendsBaseRule": true, + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-useless-constructor", + }, + "hasSuggestions": undefined, + "messages": { + "noUselessConstructor": "Useless constructor.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-useless-empty-export": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow empty exports that don't change anything in a module file", + "url": "https://typescript-eslint.io/rules/no-useless-empty-export", + }, + "fixable": "code", + "hasSuggestions": false, + "messages": { + "uselessExport": "Empty export does nothing and can be removed.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-useless-template-literals": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary template literals", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-useless-template-literals", + }, + "fixable": "code", + "messages": { + "noUselessTemplateLiteral": "Template literal expression is unnecessary and can be simplified.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-var-requires": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow \`require\` statements except in import statements", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-var-requires", + }, + "messages": { + "noVarReqs": "Require statement not part of import statement.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "description": "Patterns of import paths to allow requiring from.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "non-nullable-type-assertion-style": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce non-null assertions over explicit type casts", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/non-nullable-type-assertion-style", + }, + "fixable": "code", + "messages": { + "preferNonNullAssertion": "Use a ! assertion to more succinctly remove null and undefined from the type.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "object-curly-spacing": { + "create": [Function], + "defaultOptions": [ + "never", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing inside braces", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/object-curly-spacing", + }, + "fixable": "whitespace", + "messages": { + "requireSpaceAfter": "A space is required after '{{token}}'.", + "requireSpaceBefore": "A space is required before '{{token}}'.", + "unexpectedSpaceAfter": "There should be no space after '{{token}}'.", + "unexpectedSpaceBefore": "There should be no space before '{{token}}'.", + }, + "replacedBy": [ + "@stylistic/ts/object-curly-spacing", + ], + "schema": [ + { + "enum": [ + "always", + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "arraysInObjects": { + "type": "boolean", + }, + "objectsInObjects": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "only-throw-error": { + "create": [Function], + "defaultOptions": [ + { + "allowThrowingAny": true, + "allowThrowingUnknown": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow throwing non-\`Error\` values as exceptions", + "extendsBaseRule": "no-throw-literal", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/only-throw-error", + }, + "messages": { + "object": "Expected an error object to be thrown.", + "undef": "Do not throw undefined.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowThrowingAny": { + "type": "boolean", + }, + "allowThrowingUnknown": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "padding-line-between-statements": { + "create": [Function], + "defaultOptions": [], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow padding lines between statements", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/padding-line-between-statements", + }, + "fixable": "whitespace", + "hasSuggestions": false, + "messages": { + "expectedBlankLine": "Expected blank line before this statement.", + "unexpectedBlankLine": "Unexpected blank line before this statement.", + }, + "replacedBy": [ + "@stylistic/ts/padding-line-between-statements", + ], + "schema": { + "$defs": { + "paddingType": { + "enum": [ + "any", + "never", + "always", + ], + "type": "string", + }, + "statementType": { + "anyOf": [ + { + "enum": [ + "*", + "block-like", + "exports", + "require", + "directive", + "expression", + "iife", + "multiline-block-like", + "multiline-expression", + "multiline-const", + "multiline-let", + "multiline-var", + "singleline-const", + "singleline-let", + "singleline-var", + "block", + "empty", + "function", + "break", + "case", + "class", + "const", + "continue", + "debugger", + "default", + "do", + "export", + "for", + "if", + "import", + "let", + "return", + "switch", + "throw", + "try", + "var", + "while", + "with", + "interface", + "type", + ], + "type": "string", + }, + { + "additionalItems": false, + "items": { + "enum": [ + "*", + "block-like", + "exports", + "require", + "directive", + "expression", + "iife", + "multiline-block-like", + "multiline-expression", + "multiline-const", + "multiline-let", + "multiline-var", + "singleline-const", + "singleline-let", + "singleline-var", + "block", + "empty", + "function", + "break", + "case", + "class", + "const", + "continue", + "debugger", + "default", + "do", + "export", + "for", + "if", + "import", + "let", + "return", + "switch", + "throw", + "try", + "var", + "while", + "with", + "interface", + "type", + ], + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "additionalItems": false, + "items": { + "additionalProperties": false, + "properties": { + "blankLine": { + "$ref": "#/$defs/paddingType", + }, + "next": { + "$ref": "#/$defs/statementType", + }, + "prev": { + "$ref": "#/$defs/statementType", + }, + }, + "required": [ + "blankLine", + "prev", + "next", + ], + "type": "object", + }, + "type": "array", + }, + "type": "layout", + }, + }, + "parameter-properties": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "prefer": "class-property", + }, + ], + "meta": { + "docs": { + "description": "Require or disallow parameter properties in class constructors", + "url": "https://typescript-eslint.io/rules/parameter-properties", + }, + "messages": { + "preferClassProperty": "Property {{parameter}} should be declared as a class property.", + "preferParameterProperty": "Property {{parameter}} should be declared as a parameter property.", + }, + "schema": [ + { + "$defs": { + "modifier": { + "enum": [ + "readonly", + "private", + "protected", + "public", + "private readonly", + "protected readonly", + "public readonly", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "$ref": "#/items/0/$defs/modifier", + }, + "type": "array", + }, + "prefer": { + "enum": [ + "class-property", + "parameter-property", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "prefer-as-const": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of \`as const\` over literal type", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/prefer-as-const", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "preferConstAssertion": "Expected a \`const\` instead of a literal type assertion.", + "variableConstAssertion": "Expected a \`const\` assertion instead of a literal type annotation.", + "variableSuggest": "You should use \`as const\` instead of type annotation.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-destructuring": { + "create": [Function], + "defaultOptions": [ + { + "AssignmentExpression": { + "array": true, + "object": true, + }, + "VariableDeclarator": { + "array": true, + "object": true, + }, + }, + {}, + ], + "meta": { + "docs": { + "description": "Require destructuring from arrays and/or objects", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-destructuring", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "preferDestructuring": "Use {{type}} destructuring.", + }, + "schema": [ + { + "oneOf": [ + { + "additionalProperties": false, + "properties": { + "AssignmentExpression": { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + "VariableDeclarator": { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + { + "properties": { + "enforceForDeclarationWithTypeAnnotation": { + "type": "boolean", + }, + "enforceForRenamedProperties": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-enum-initializers": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require each enum member value to be explicitly initialized", + "url": "https://typescript-eslint.io/rules/prefer-enum-initializers", + }, + "hasSuggestions": true, + "messages": { + "defineInitializer": "The value of the member '{{ name }}' should be explicitly defined.", + "defineInitializerSuggestion": "Can be fixed to {{ name }} = {{ suggested }}", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-find": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of Array.prototype.find() over Array.prototype.filter() followed by [0] when looking for a single result", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-find", + }, + "hasSuggestions": true, + "messages": { + "preferFind": "Prefer .find(...) instead of .filter(...)[0].", + "preferFindSuggestion": "Use .find(...) instead of .filter(...)[0].", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-for-of": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of \`for-of\` loop over the standard \`for\` loop where possible", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-for-of", + }, + "messages": { + "preferForOf": "Expected a \`for-of\` loop instead of a \`for\` loop with this simple iteration.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-function-type": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using function types instead of interfaces with call signatures", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-function-type", + }, + "fixable": "code", + "messages": { + "functionTypeOverCallableType": "{{ literalOrInterface }} only has a call signature, you should use a function type instead.", + "unexpectedThisOnFunctionOnlyInterface": "\`this\` refers to the function type '{{ interfaceName }}', did you intend to use a generic \`this\` parameter like \`(this: Self, ...) => Self\` instead?", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-includes": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce \`includes\` method over \`indexOf\` method", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-includes", + }, + "fixable": "code", + "messages": { + "preferIncludes": "Use 'includes()' method instead.", + "preferStringIncludes": "Use \`String#includes()\` method with a string instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-literal-enum-member": { + "create": [Function], + "defaultOptions": [ + { + "allowBitwiseExpressions": false, + }, + ], + "meta": { + "docs": { + "description": "Require all enum members to be literal values", + "recommended": "strict", + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/prefer-literal-enum-member", + }, + "messages": { + "notLiteral": "Explicit enum value must only be a literal value (string, number, boolean, etc).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowBitwiseExpressions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-namespace-keyword": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require using \`namespace\` keyword over \`module\` keyword to declare custom TypeScript modules", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-namespace-keyword", + }, + "fixable": "code", + "messages": { + "useNamespace": "Use 'namespace' instead of 'module' to declare custom TypeScript modules.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-nullish-coalescing": { + "create": [Function], + "defaultOptions": [ + { + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + "ignoreConditionalTests": false, + "ignoreMixedLogicalExpressions": false, + "ignorePrimitives": { + "bigint": false, + "boolean": false, + "number": false, + "string": false, + }, + "ignoreTernaryTests": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce using the nullish coalescing operator instead of logical assignments or chaining", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-nullish-coalescing", + }, + "hasSuggestions": true, + "messages": { + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + "preferNullishOverOr": "Prefer using nullish coalescing operator (\`??\`) instead of a logical or (\`||\`), as it is a safer operator.", + "preferNullishOverTernary": "Prefer using nullish coalescing operator (\`??\`) instead of a ternary expression, as it is simpler to read.", + "suggestNullish": "Fix to nullish coalescing operator (\`??\`).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "type": "boolean", + }, + "ignoreConditionalTests": { + "type": "boolean", + }, + "ignoreMixedLogicalExpressions": { + "type": "boolean", + }, + "ignorePrimitives": { + "oneOf": [ + { + "properties": { + "bigint": { + "type": "boolean", + }, + "boolean": { + "type": "boolean", + }, + "number": { + "type": "boolean", + }, + "string": { + "type": "boolean", + }, + }, + "type": "object", + }, + { + "enum": [ + true, + ], + "type": "boolean", + }, + ], + }, + "ignoreTernaryTests": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-optional-chain": { + "create": [Function], + "defaultOptions": [ + { + "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": false, + "checkAny": true, + "checkBigInt": true, + "checkBoolean": true, + "checkNumber": true, + "checkString": true, + "checkUnknown": true, + "requireNullish": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce using concise optional chain expressions instead of chained logical ands, negated logical ors, or empty objects", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-optional-chain", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "optionalChainSuggest": "Change to an optional chain.", + "preferOptionalChain": "Prefer using an optional chain expression instead, as it's more concise and easier to read.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": { + "description": "Allow autofixers that will change the return type of the expression. This option is considered unsafe as it may break the build.", + "type": "boolean", + }, + "checkAny": { + "description": "Check operands that are typed as \`any\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkBigInt": { + "description": "Check operands that are typed as \`bigint\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkBoolean": { + "description": "Check operands that are typed as \`boolean\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkNumber": { + "description": "Check operands that are typed as \`number\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkString": { + "description": "Check operands that are typed as \`string\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkUnknown": { + "description": "Check operands that are typed as \`unknown\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "requireNullish": { + "description": "Skip operands that are not typed with \`null\` and/or \`undefined\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-promise-reject-errors": { + "create": [Function], + "defaultOptions": [ + { + "allowEmptyReject": false, + }, + ], + "meta": { + "docs": { + "description": "Require using Error objects as Promise rejection reasons", + "extendsBaseRule": true, + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-promise-reject-errors", + }, + "messages": { + "rejectAnError": "Expected the Promise rejection reason to be an Error.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowEmptyReject": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-readonly": { + "create": [Function], + "defaultOptions": [ + { + "onlyInlineLambdas": false, + }, + ], + "meta": { + "docs": { + "description": "Require private members to be marked as \`readonly\` if they're never modified outside of the constructor", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-readonly", + }, + "fixable": "code", + "messages": { + "preferReadonly": "Member '{{name}}' is never reassigned; mark it as \`readonly\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "onlyInlineLambdas": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-readonly-parameter-types": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "checkParameterProperties": true, + "ignoreInferredTypes": false, + "treatMethodsAsReadonly": false, + }, + ], + "meta": { + "docs": { + "description": "Require function parameters to be typed as \`readonly\` to prevent accidental mutation of inputs", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-readonly-parameter-types", + }, + "messages": { + "shouldBeReadonly": "Parameter should be a read only type.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "oneOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "file", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + "path": { + "type": "string", + }, + }, + "required": [ + "from", + "name", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "lib", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "required": [ + "from", + "name", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "package", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + "package": { + "type": "string", + }, + }, + "required": [ + "from", + "name", + "package", + ], + "type": "object", + }, + ], + }, + "type": "array", + }, + "checkParameterProperties": { + "type": "boolean", + }, + "ignoreInferredTypes": { + "type": "boolean", + }, + "treatMethodsAsReadonly": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-reduce-type-parameter": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using type parameter when calling \`Array#reduce\` instead of casting", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-reduce-type-parameter", + }, + "fixable": "code", + "messages": { + "preferTypeParameter": "Unnecessary cast: Array#reduce accepts a type parameter for the default value.", + }, + "schema": [], + "type": "problem", + }, + }, + "prefer-regexp-exec": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce \`RegExp#exec\` over \`String#match\` if no global flag is provided", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-regexp-exec", + }, + "fixable": "code", + "messages": { + "regExpExecOverStringMatch": "Use the \`RegExp#exec()\` method instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-return-this-type": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce that \`this\` is used when only \`this\` type is returned", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-return-this-type", + }, + "fixable": "code", + "messages": { + "useThisType": "Use \`this\` type instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-string-starts-ends-with": { + "create": [Function], + "defaultOptions": [ + { + "allowSingleElementEquality": "never", + }, + ], + "meta": { + "docs": { + "description": "Enforce using \`String#startsWith\` and \`String#endsWith\` over other equivalent methods of checking substrings", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-string-starts-ends-with", + }, + "fixable": "code", + "messages": { + "preferEndsWith": "Use the 'String#endsWith' method instead.", + "preferStartsWith": "Use 'String#startsWith' method instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowSingleElementEquality": { + "description": "Whether to allow equality checks against the first or last element of a string.", + "enum": [ + "always", + "never", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-ts-expect-error": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using \`@ts-expect-error\` over \`@ts-ignore\`", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/prefer-ts-expect-error", + }, + "fixable": "code", + "messages": { + "preferExpectErrorComment": "Use "@ts-expect-error" to ensure an error is actually being suppressed.", + }, + "schema": [], + "type": "problem", + }, + }, + "promise-function-async": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowedPromiseNames": [], + "checkArrowFunctions": true, + "checkFunctionDeclarations": true, + "checkFunctionExpressions": true, + "checkMethodDeclarations": true, + }, + ], + "meta": { + "docs": { + "description": "Require any function or method that returns a Promise to be marked async", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/promise-function-async", + }, + "fixable": "code", + "messages": { + "missingAsync": "Functions that return promises must be async.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to consider \`any\` and \`unknown\` to be Promises.", + "type": "boolean", + }, + "allowedPromiseNames": { + "description": "Any extra names of classes or interfaces to be considered Promises.", + "items": { + "type": "string", + }, + "type": "array", + }, + "checkArrowFunctions": { + "type": "boolean", + }, + "checkFunctionDeclarations": { + "type": "boolean", + }, + "checkFunctionExpressions": { + "type": "boolean", + }, + "checkMethodDeclarations": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "quotes": { + "create": [Function], + "defaultOptions": [ + "double", + { + "allowTemplateLiterals": false, + "avoidEscape": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce the consistent use of either backticks, double, or single quotes", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/quotes", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "wrongQuotes": "Strings must use {{description}}.", + }, + "replacedBy": [ + "@stylistic/ts/quotes", + ], + "schema": [ + { + "enum": [ + "single", + "double", + "backtick", + ], + }, + { + "anyOf": [ + { + "enum": [ + "avoid-escape", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowTemplateLiterals": { + "type": "boolean", + }, + "avoidEscape": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "require-array-sort-compare": { + "create": [Function], + "defaultOptions": [ + { + "ignoreStringArrays": true, + }, + ], + "meta": { + "docs": { + "description": "Require \`Array#sort\` and \`Array#toSorted\` calls to always provide a \`compareFunction\`", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/require-array-sort-compare", + }, + "messages": { + "requireCompare": "Require 'compare' argument.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreStringArrays": { + "description": "Whether to ignore arrays in which all elements are strings.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "require-await": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow async functions which have no \`await\` expression", + "extendsBaseRule": true, + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/require-await", + }, + "messages": { + "missingAwait": "{{name}} has no 'await' expression.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "restrict-plus-operands": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowBoolean": true, + "allowNullish": true, + "allowNumberAndString": true, + "allowRegExp": true, + "skipCompoundAssignments": false, + }, + ], + "meta": { + "docs": { + "description": "Require both operands of addition to be the same type and be \`bigint\`, \`number\`, or \`string\`", + "recommended": { + "recommended": true, + "strict": [ + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + }, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/restrict-plus-operands", + }, + "messages": { + "bigintAndNumber": "Numeric '+' operations must either be both bigints or both numbers. Got \`{{left}}\` + \`{{right}}\`.", + "invalid": "Invalid operand for a '+' operation. Operands must each be a number or {{stringLike}}. Got \`{{type}}\`.", + "mismatched": "Operands of '+' operations must be a number or {{stringLike}}. Got \`{{left}}\` + \`{{right}}\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to allow \`any\` typed values.", + "type": "boolean", + }, + "allowBoolean": { + "description": "Whether to allow \`boolean\` typed values.", + "type": "boolean", + }, + "allowNullish": { + "description": "Whether to allow potentially \`null\` or \`undefined\` typed values.", + "type": "boolean", + }, + "allowNumberAndString": { + "description": "Whether to allow \`bigint\`/\`number\` typed values and \`string\` typed values to be added together.", + "type": "boolean", + }, + "allowRegExp": { + "description": "Whether to allow \`regexp\` typed values.", + "type": "boolean", + }, + "skipCompoundAssignments": { + "description": "Whether to skip compound assignments such as \`+=\`.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "restrict-template-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowBoolean": true, + "allowNullish": true, + "allowNumber": true, + "allowRegExp": true, + }, + ], + "meta": { + "docs": { + "description": "Enforce template literal expressions to be of \`string\` type", + "recommended": { + "recommended": true, + "strict": [ + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + }, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/restrict-template-expressions", + }, + "messages": { + "invalidType": "Invalid type "{{type}}" of template literal expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to allow \`any\` typed values in template expressions.", + "type": "boolean", + }, + "allowArray": { + "description": "Whether to allow \`array\` typed values in template expressions.", + "type": "boolean", + }, + "allowBoolean": { + "description": "Whether to allow \`boolean\` typed values in template expressions.", + "type": "boolean", + }, + "allowNever": { + "description": "Whether to allow \`never\` typed values in template expressions.", + "type": "boolean", + }, + "allowNullish": { + "description": "Whether to allow \`nullish\` typed values in template expressions.", + "type": "boolean", + }, + "allowNumber": { + "description": "Whether to allow \`number\` typed values in template expressions.", + "type": "boolean", + }, + "allowRegExp": { + "description": "Whether to allow \`regexp\` typed values in template expressions.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "return-await": { + "create": [Function], + "defaultOptions": [ + "in-try-catch", + ], + "meta": { + "docs": { + "description": "Enforce consistent returning of awaited values", + "extendsBaseRule": "no-return-await", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/return-await", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "disallowedPromiseAwait": "Returning an awaited promise is not allowed in this context.", + "nonPromiseAwait": "Returning an awaited value that is not a promise is not allowed.", + "requiredPromiseAwait": "Returning an awaited promise is required in this context.", + }, + "schema": [ + { + "enum": [ + "in-try-catch", + "always", + "never", + ], + "type": "string", + }, + ], + "type": "problem", + }, + }, + "semi": { + "create": [Function], + "defaultOptions": [ + "always", + { + "beforeStatementContinuationChars": "any", + "omitLastInOneLineBlock": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow semicolons instead of ASI", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/semi", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "extraSemi": "Extra semicolon.", + "missingSemi": "Missing semicolon.", + }, + "replacedBy": [ + "@stylistic/ts/semi", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "beforeStatementContinuationChars": { + "enum": [ + "always", + "any", + "never", + ], + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "always", + ], + }, + { + "additionalProperties": false, + "properties": { + "omitLastInOneLineBlock": { + "type": "boolean", + }, + "omitLastInOneLineClassBody": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "sort-type-constituents": { + "create": [Function], + "defaultOptions": [ + { + "checkIntersections": true, + "checkUnions": true, + "groupOrder": [ + "named", + "keyword", + "operator", + "literal", + "function", + "import", + "conditional", + "object", + "tuple", + "intersection", + "union", + "nullish", + ], + }, + ], + "meta": { + "docs": { + "description": "Enforce constituents of a type union/intersection to be sorted alphabetically", + "url": "https://typescript-eslint.io/rules/sort-type-constituents", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "notSorted": "{{type}} type constituents must be sorted.", + "notSortedNamed": "{{type}} type {{name}} constituents must be sorted.", + "suggestFix": "Sort constituents of type (removes all comments).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checkIntersections": { + "description": "Whether to check intersection types.", + "type": "boolean", + }, + "checkUnions": { + "description": "Whether to check union types.", + "type": "boolean", + }, + "groupOrder": { + "description": "Ordering of the groups.", + "items": { + "enum": [ + "conditional", + "function", + "import", + "intersection", + "keyword", + "nullish", + "literal", + "named", + "object", + "operator", + "tuple", + "union", + ], + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "space-before-blocks": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before blocks", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-before-blocks", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "missingSpace": "Missing space before opening brace.", + "unexpectedSpace": "Unexpected space before opening brace.", + }, + "replacedBy": [ + "@stylistic/ts/space-before-blocks", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "always", + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "classes": { + "enum": [ + "always", + "never", + "off", + ], + }, + "functions": { + "enum": [ + "always", + "never", + "off", + ], + }, + "keywords": { + "enum": [ + "always", + "never", + "off", + ], + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "space-before-function-paren": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before function parenthesis", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-before-function-paren", + }, + "fixable": "whitespace", + "messages": { + "missing": "Missing space before function parentheses.", + "unexpected": "Unexpected space before function parentheses.", + }, + "replacedBy": [ + "@stylistic/ts/space-before-function-paren", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "anonymous": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + "asyncArrow": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + "named": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "space-infix-ops": { + "create": [Function], + "defaultOptions": [ + { + "int32Hint": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require spacing around infix operators", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-infix-ops", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "missingSpace": "Operator '{{operator}}' must be spaced.", + }, + "replacedBy": [ + "@stylistic/ts/space-infix-ops", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "int32Hint": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "strict-boolean-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": false, + "allowNullableBoolean": false, + "allowNullableEnum": false, + "allowNullableNumber": false, + "allowNullableObject": true, + "allowNullableString": false, + "allowNumber": true, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + "allowString": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow certain types in boolean expressions", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/strict-boolean-expressions", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "conditionErrorAny": "Unexpected any value in conditional. An explicit comparison or type cast is required.", + "conditionErrorNullableBoolean": "Unexpected nullable boolean value in conditional. Please handle the nullish case explicitly.", + "conditionErrorNullableEnum": "Unexpected nullable enum value in conditional. Please handle the nullish/zero/NaN cases explicitly.", + "conditionErrorNullableNumber": "Unexpected nullable number value in conditional. Please handle the nullish/zero/NaN cases explicitly.", + "conditionErrorNullableObject": "Unexpected nullable object value in conditional. An explicit null check is required.", + "conditionErrorNullableString": "Unexpected nullable string value in conditional. Please handle the nullish/empty cases explicitly.", + "conditionErrorNullish": "Unexpected nullish value in conditional. The condition is always false.", + "conditionErrorNumber": "Unexpected number value in conditional. An explicit zero/NaN check is required.", + "conditionErrorObject": "Unexpected object value in conditional. The condition is always true.", + "conditionErrorOther": "Unexpected value in conditional. A boolean expression is required.", + "conditionErrorString": "Unexpected string value in conditional. An explicit empty string check is required.", + "conditionFixCastBoolean": "Explicitly cast value to a boolean (\`Boolean(value)\`)", + "conditionFixCompareEmptyString": "Change condition to check for empty string (\`value !== ""\`)", + "conditionFixCompareFalse": "Change condition to check if false (\`value === false\`)", + "conditionFixCompareNaN": "Change condition to check for NaN (\`!Number.isNaN(value)\`)", + "conditionFixCompareNullish": "Change condition to check for null/undefined (\`value != null\`)", + "conditionFixCompareStringLength": "Change condition to check string's length (\`value.length !== 0\`)", + "conditionFixCompareTrue": "Change condition to check if true (\`value === true\`)", + "conditionFixCompareZero": "Change condition to check for 0 (\`value !== 0\`)", + "conditionFixDefaultEmptyString": "Explicitly treat nullish value the same as an empty string (\`value ?? ""\`)", + "conditionFixDefaultFalse": "Explicitly treat nullish value the same as false (\`value ?? false\`)", + "conditionFixDefaultZero": "Explicitly treat nullish value the same as 0 (\`value ?? 0\`)", + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "type": "boolean", + }, + "allowNullableBoolean": { + "type": "boolean", + }, + "allowNullableEnum": { + "type": "boolean", + }, + "allowNullableNumber": { + "type": "boolean", + }, + "allowNullableObject": { + "type": "boolean", + }, + "allowNullableString": { + "type": "boolean", + }, + "allowNumber": { + "type": "boolean", + }, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "type": "boolean", + }, + "allowString": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "switch-exhaustiveness-check": { + "create": [Function], + "defaultOptions": [ + { + "allowDefaultCaseForExhaustiveSwitch": true, + "requireDefaultForNonUnion": false, + }, + ], + "meta": { + "docs": { + "description": "Require switch-case statements to be exhaustive", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/switch-exhaustiveness-check", + }, + "hasSuggestions": true, + "messages": { + "addMissingCases": "Add branches for missing cases.", + "dangerousDefaultCase": "The switch statement is exhaustive, so the default case is unnecessary.", + "switchIsNotExhaustive": "Switch is not exhaustive. Cases not matched: {{missingBranches}}", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDefaultCaseForExhaustiveSwitch": { + "description": "If 'true', allow 'default' cases on switch statements with exhaustive cases.", + "type": "boolean", + }, + "requireDefaultForNonUnion": { + "description": "If 'true', require a 'default' clause for switches on non-union types.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "triple-slash-reference": { + "create": [Function], + "defaultOptions": [ + { + "lib": "always", + "path": "never", + "types": "prefer-import", + }, + ], + "meta": { + "docs": { + "description": "Disallow certain triple slash directives in favor of ES6-style import declarations", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/triple-slash-reference", + }, + "messages": { + "tripleSlashReference": "Do not use a triple slash reference for {{module}}, use \`import\` style instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "lib": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + "path": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + "types": { + "enum": [ + "always", + "never", + "prefer-import", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "type-annotation-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require consistent spacing around type annotations", + "url": "https://typescript-eslint.io/rules/type-annotation-spacing", + }, + "fixable": "whitespace", + "messages": { + "expectedSpaceAfter": "Expected a space after the '{{type}}'.", + "expectedSpaceBefore": "Expected a space before the '{{type}}'.", + "unexpectedSpaceAfter": "Unexpected space after the '{{type}}'.", + "unexpectedSpaceBefore": "Unexpected space before the '{{type}}'.", + "unexpectedSpaceBetween": "Unexpected space between the '{{previousToken}}' and the '{{type}}'.", + }, + "replacedBy": [ + "@stylistic/ts/type-annotation-spacing", + ], + "schema": [ + { + "$defs": { + "spacingConfig": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "arrow": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "colon": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "parameter": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "property": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "returnType": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "variable": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "typedef": { + "create": [Function], + "defaultOptions": [ + { + "arrayDestructuring": false, + "arrowParameter": false, + "memberVariableDeclaration": false, + "objectDestructuring": false, + "parameter": false, + "propertyDeclaration": false, + "variableDeclaration": false, + "variableDeclarationIgnoreFunction": false, + }, + ], + "meta": { + "docs": { + "description": "Require type annotations in certain places", + "url": "https://typescript-eslint.io/rules/typedef", + }, + "messages": { + "expectedTypedef": "Expected a type annotation.", + "expectedTypedefNamed": "Expected {{name}} to have a type annotation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "arrayDestructuring": { + "type": "boolean", + }, + "arrowParameter": { + "type": "boolean", + }, + "memberVariableDeclaration": { + "type": "boolean", + }, + "objectDestructuring": { + "type": "boolean", + }, + "parameter": { + "type": "boolean", + }, + "propertyDeclaration": { + "type": "boolean", + }, + "variableDeclaration": { + "type": "boolean", + }, + "variableDeclarationIgnoreFunction": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "unbound-method": { + "create": [Function], + "defaultOptions": [ + { + "ignoreStatic": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce unbound methods are called with their expected scope", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/unbound-method", + }, + "messages": { + "unbound": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`.", + "unboundWithoutThisAnnotation": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`. +If your function does not access \`this\`, you can annotate it with \`this: void\`, or consider using an arrow function instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreStatic": { + "description": "Whether to skip checking whether \`static\` methods are correctly bound.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "unified-signatures": { + "create": [Function], + "defaultOptions": [ + { + "ignoreDifferentlyNamedParameters": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow two overloads that could be unified into one with a union or an optional/rest parameter", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/unified-signatures", + }, + "messages": { + "omittingRestParameter": "{{failureStringStart}} with a rest parameter.", + "omittingSingleParameter": "{{failureStringStart}} with an optional parameter.", + "singleParameterDifference": "{{failureStringStart}} taking \`{{type1}} | {{type2}}\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreDifferentlyNamedParameters": { + "description": "Whether two parameters with different names at the same index should be considered different even if their types are the same.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "use-unknown-in-catch-callback-variable": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce typing arguments in \`.catch()\` callbacks as \`unknown\`", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/use-unknown-in-catch-callback-variable", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "addUnknownRestTypeAnnotationSuggestion": "Add an explicit \`: [unknown]\` type annotation to the catch rest variable.", + "addUnknownTypeAnnotationSuggestion": "Add an explicit \`: unknown\` type annotation to the catch variable.", + "useUnknown": "Prefer the safe \`: unknown\` for a catch callback variable.", + "useUnknownArrayDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may not be iterable.", + "useUnknownObjectDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may be nullable, or may not have the expected shape.", + "useUnknownSpreadArgs": "Prefer the safe \`: unknown\` for a catch callback variable. The argument list may contain a handler that does not use \`unknown\` for the catch callback variable.", + "wrongRestTypeAnnotationSuggestion": "Change existing type annotation to \`: [unknown]\`.", + "wrongTypeAnnotationSuggestion": "Change existing type annotation to \`: unknown\`.", + }, + "schema": [], + "type": "suggestion", + }, + }, + }, + }, + }, + }, + { + "files": [ + "**/*.ts", + "**/*.tsx", + "**/*.mts", + "**/*.cts", + ], + "name": "typescript-eslint/eslint-recommended", + "rules": { + "constructor-super": "off", + "getter-return": "off", + "no-const-assign": "off", + "no-dupe-args": "off", + "no-dupe-class-members": "off", + "no-dupe-keys": "off", + "no-func-assign": "off", + "no-import-assign": "off", + "no-new-symbol": "off", + "no-obj-calls": "off", + "no-redeclare": "off", + "no-setter-return": "off", + "no-this-before-super": "off", + "no-undef": "off", + "no-unreachable": "off", + "no-unsafe-negation": "off", + "no-var": "error", + "prefer-const": "error", + "prefer-rest-params": "error", + "prefer-spread": "error", + }, + }, + { + "name": "typescript-eslint/strict-type-checked", + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": [ + "error", + { + "minimumDescriptionLength": 10, + }, + ], + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/restrict-template-expressions": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/unified-signatures": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-throw-literal": "off", + "no-unused-vars": "off", + "no-useless-constructor": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + { + "languageOptions": { + "parser": { + "meta": { + "name": "typescript-eslint/parser", + "version": "7.6.0", + }, + "parseForESLint": [Function], + }, + "sourceType": "module", + }, + "name": "typescript-eslint/base", + "plugins": { + "@typescript-eslint": { + "configs": { + "all": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/class-methods-use-this": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-return": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/consistent-type-exports": "error", + "@typescript-eslint/consistent-type-imports": "error", + "@typescript-eslint/default-param-last": "error", + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/explicit-function-return-type": "error", + "@typescript-eslint/explicit-member-accessibility": "error", + "@typescript-eslint/explicit-module-boundary-types": "error", + "@typescript-eslint/init-declarations": "error", + "@typescript-eslint/max-params": "error", + "@typescript-eslint/member-ordering": "error", + "@typescript-eslint/method-signature-style": "error", + "@typescript-eslint/naming-convention": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-dupe-class-members": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-import-type-side-effects": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/no-invalid-this": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loop-func": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-magic-numbers": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-redeclare": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-require-imports": "error", + "@typescript-eslint/no-restricted-imports": "error", + "@typescript-eslint/no-shadow": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-qualifier": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unsafe-unary-minus": "error", + "@typescript-eslint/no-unused-expressions": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-use-before-define": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-useless-empty-export": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/parameter-properties": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-destructuring": "error", + "@typescript-eslint/prefer-enum-initializers": "error", + "@typescript-eslint/prefer-find": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-readonly": "error", + "@typescript-eslint/prefer-readonly-parameter-types": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-regexp-exec": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/promise-function-async": "error", + "@typescript-eslint/require-array-sort-compare": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/return-await": "error", + "@typescript-eslint/sort-type-constituents": "error", + "@typescript-eslint/strict-boolean-expressions": "error", + "@typescript-eslint/switch-exhaustiveness-check": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/typedef": "error", + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/unified-signatures": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "class-methods-use-this": "off", + "consistent-return": "off", + "default-param-last": "off", + "dot-notation": "off", + "init-declarations": "off", + "max-params": "off", + "no-array-constructor": "off", + "no-dupe-class-members": "off", + "no-empty-function": "off", + "no-implied-eval": "off", + "no-invalid-this": "off", + "no-loop-func": "off", + "no-loss-of-precision": "off", + "no-magic-numbers": "off", + "no-redeclare": "off", + "no-restricted-imports": "off", + "no-return-await": "off", + "no-shadow": "off", + "no-throw-literal": "off", + "no-unused-expressions": "off", + "no-unused-vars": "off", + "no-use-before-define": "off", + "no-useless-constructor": "off", + "prefer-destructuring": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "base": { + "parser": "@typescript-eslint/parser", + "parserOptions": { + "sourceType": "module", + }, + "plugins": [ + "@typescript-eslint", + ], + }, + "disable-type-checked": { + "parserOptions": { + "program": null, + "project": false, + }, + "rules": { + "@typescript-eslint/await-thenable": "off", + "@typescript-eslint/consistent-return": "off", + "@typescript-eslint/consistent-type-exports": "off", + "@typescript-eslint/dot-notation": "off", + "@typescript-eslint/naming-convention": "off", + "@typescript-eslint/no-array-delete": "off", + "@typescript-eslint/no-base-to-string": "off", + "@typescript-eslint/no-confusing-void-expression": "off", + "@typescript-eslint/no-duplicate-type-constituents": "off", + "@typescript-eslint/no-floating-promises": "off", + "@typescript-eslint/no-for-in-array": "off", + "@typescript-eslint/no-implied-eval": "off", + "@typescript-eslint/no-meaningless-void-operator": "off", + "@typescript-eslint/no-misused-promises": "off", + "@typescript-eslint/no-mixed-enums": "off", + "@typescript-eslint/no-redundant-type-constituents": "off", + "@typescript-eslint/no-throw-literal": "off", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off", + "@typescript-eslint/no-unnecessary-condition": "off", + "@typescript-eslint/no-unnecessary-qualifier": "off", + "@typescript-eslint/no-unnecessary-type-arguments": "off", + "@typescript-eslint/no-unnecessary-type-assertion": "off", + "@typescript-eslint/no-unsafe-argument": "off", + "@typescript-eslint/no-unsafe-assignment": "off", + "@typescript-eslint/no-unsafe-call": "off", + "@typescript-eslint/no-unsafe-enum-comparison": "off", + "@typescript-eslint/no-unsafe-member-access": "off", + "@typescript-eslint/no-unsafe-return": "off", + "@typescript-eslint/no-unsafe-unary-minus": "off", + "@typescript-eslint/no-useless-template-literals": "off", + "@typescript-eslint/non-nullable-type-assertion-style": "off", + "@typescript-eslint/only-throw-error": "off", + "@typescript-eslint/prefer-destructuring": "off", + "@typescript-eslint/prefer-find": "off", + "@typescript-eslint/prefer-includes": "off", + "@typescript-eslint/prefer-nullish-coalescing": "off", + "@typescript-eslint/prefer-optional-chain": "off", + "@typescript-eslint/prefer-promise-reject-errors": "off", + "@typescript-eslint/prefer-readonly": "off", + "@typescript-eslint/prefer-readonly-parameter-types": "off", + "@typescript-eslint/prefer-reduce-type-parameter": "off", + "@typescript-eslint/prefer-regexp-exec": "off", + "@typescript-eslint/prefer-return-this-type": "off", + "@typescript-eslint/prefer-string-starts-ends-with": "off", + "@typescript-eslint/promise-function-async": "off", + "@typescript-eslint/require-array-sort-compare": "off", + "@typescript-eslint/require-await": "off", + "@typescript-eslint/restrict-plus-operands": "off", + "@typescript-eslint/restrict-template-expressions": "off", + "@typescript-eslint/return-await": "off", + "@typescript-eslint/strict-boolean-expressions": "off", + "@typescript-eslint/switch-exhaustiveness-check": "off", + "@typescript-eslint/unbound-method": "off", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "off", + }, + }, + "eslint-recommended": { + "overrides": [ + { + "files": [ + "*.ts", + "*.tsx", + "*.mts", + "*.cts", + ], + "rules": { + "constructor-super": "off", + "getter-return": "off", + "no-const-assign": "off", + "no-dupe-args": "off", + "no-dupe-class-members": "off", + "no-dupe-keys": "off", + "no-func-assign": "off", + "no-import-assign": "off", + "no-new-symbol": "off", + "no-obj-calls": "off", + "no-redeclare": "off", + "no-setter-return": "off", + "no-this-before-super": "off", + "no-undef": "off", + "no-unreachable": "off", + "no-unsafe-negation": "off", + "no-var": "error", + "prefer-const": "error", + "prefer-rest-params": "error", + "prefer-spread": "error", + }, + }, + ], + }, + "recommended": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/triple-slash-reference": "error", + "no-array-constructor": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + }, + }, + "recommended-requiring-type-checking": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "require-await": "off", + }, + }, + "recommended-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": "error", + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "require-await": "off", + }, + }, + "recommended-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": "error", + "@typescript-eslint/restrict-template-expressions": "error", + "@typescript-eslint/unbound-method": "error", + "no-implied-eval": "off", + "require-await": "off", + }, + }, + "strict": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/ban-ts-comment": [ + "error", + { + "minimumDescriptionLength": 10, + }, + ], + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unified-signatures": "error", + "no-array-constructor": "off", + "no-loss-of-precision": "off", + "no-unused-vars": "off", + "no-useless-constructor": "off", + }, + }, + "strict-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/ban-ts-comment": [ + "error", + { + "minimumDescriptionLength": 10, + }, + ], + "@typescript-eslint/ban-types": "error", + "@typescript-eslint/no-array-constructor": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-duplicate-enum-values": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-dynamic-delete": "error", + "@typescript-eslint/no-explicit-any": "error", + "@typescript-eslint/no-extra-non-null-assertion": "error", + "@typescript-eslint/no-extraneous-class": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-invalid-void-type": "error", + "@typescript-eslint/no-loss-of-precision": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-new": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-namespace": "error", + "@typescript-eslint/no-non-null-asserted-nullish-coalescing": "error", + "@typescript-eslint/no-non-null-asserted-optional-chain": "error", + "@typescript-eslint/no-non-null-assertion": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-this-alias": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unnecessary-type-constraint": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-declaration-merging": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-unused-vars": "error", + "@typescript-eslint/no-useless-constructor": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/no-var-requires": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/prefer-as-const": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-literal-enum-member": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/prefer-ts-expect-error": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/restrict-template-expressions": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/triple-slash-reference": "error", + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/unified-signatures": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "no-array-constructor": "off", + "no-implied-eval": "off", + "no-loss-of-precision": "off", + "no-throw-literal": "off", + "no-unused-vars": "off", + "no-useless-constructor": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "strict-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/await-thenable": "error", + "@typescript-eslint/no-array-delete": "error", + "@typescript-eslint/no-base-to-string": "error", + "@typescript-eslint/no-confusing-void-expression": "error", + "@typescript-eslint/no-duplicate-type-constituents": "error", + "@typescript-eslint/no-floating-promises": "error", + "@typescript-eslint/no-for-in-array": "error", + "@typescript-eslint/no-implied-eval": "error", + "@typescript-eslint/no-meaningless-void-operator": "error", + "@typescript-eslint/no-misused-promises": "error", + "@typescript-eslint/no-mixed-enums": "error", + "@typescript-eslint/no-redundant-type-constituents": "error", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "error", + "@typescript-eslint/no-unnecessary-condition": "error", + "@typescript-eslint/no-unnecessary-type-arguments": "error", + "@typescript-eslint/no-unnecessary-type-assertion": "error", + "@typescript-eslint/no-unsafe-argument": "error", + "@typescript-eslint/no-unsafe-assignment": "error", + "@typescript-eslint/no-unsafe-call": "error", + "@typescript-eslint/no-unsafe-enum-comparison": "error", + "@typescript-eslint/no-unsafe-member-access": "error", + "@typescript-eslint/no-unsafe-return": "error", + "@typescript-eslint/no-useless-template-literals": "error", + "@typescript-eslint/only-throw-error": "error", + "@typescript-eslint/prefer-includes": "error", + "@typescript-eslint/prefer-promise-reject-errors": "error", + "@typescript-eslint/prefer-reduce-type-parameter": "error", + "@typescript-eslint/prefer-return-this-type": "error", + "@typescript-eslint/require-await": "error", + "@typescript-eslint/restrict-plus-operands": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/restrict-template-expressions": [ + "error", + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + "@typescript-eslint/unbound-method": "error", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "error", + "no-implied-eval": "off", + "no-throw-literal": "off", + "prefer-promise-reject-errors": "off", + "require-await": "off", + }, + }, + "stylistic": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "no-empty-function": "off", + }, + }, + "stylistic-type-checked": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "dot-notation": "off", + "no-empty-function": "off", + }, + }, + "stylistic-type-checked-only": { + "extends": [ + "./configs/base", + "./configs/eslint-recommended", + ], + "rules": { + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "dot-notation": "off", + }, + }, + }, + "meta": { + "name": "@typescript-eslint/eslint-plugin", + "version": "7.6.0", + }, + "rules": { + "adjacent-overload-signatures": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require that function overload signatures be consecutive", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/adjacent-overload-signatures", + }, + "messages": { + "adjacentSignature": "All {{name}} signatures should be adjacent.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "array-type": { + "create": [Function], + "defaultOptions": [ + { + "default": "array", + }, + ], + "meta": { + "docs": { + "description": "Require consistently using either \`T[]\` or \`Array\` for arrays", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/array-type", + }, + "fixable": "code", + "messages": { + "errorStringArray": "Array type using '{{className}}<{{type}}>' is forbidden. Use '{{readonlyPrefix}}{{type}}[]' instead.", + "errorStringArraySimple": "Array type using '{{className}}<{{type}}>' is forbidden for simple types. Use '{{readonlyPrefix}}{{type}}[]' instead.", + "errorStringGeneric": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden. Use '{{className}}<{{type}}>' instead.", + "errorStringGenericSimple": "Array type using '{{readonlyPrefix}}{{type}}[]' is forbidden for non-simple types. Use '{{className}}<{{type}}>' instead.", + }, + "schema": [ + { + "$defs": { + "arrayOption": { + "enum": [ + "array", + "generic", + "array-simple", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "default": { + "$ref": "#/items/0/$defs/arrayOption", + "description": "The array type expected for mutable cases.", + }, + "readonly": { + "$ref": "#/items/0/$defs/arrayOption", + "description": "The array type expected for readonly cases. If omitted, the value for \`default\` will be used.", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "await-thenable": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow awaiting a value that is not a Thenable", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/await-thenable", + }, + "hasSuggestions": true, + "messages": { + "await": "Unexpected \`await\` of a non-Promise (non-"Thenable") value.", + "removeAwait": "Remove unnecessary \`await\`.", + }, + "schema": [], + "type": "problem", + }, + }, + "ban-ts-comment": { + "create": [Function], + "defaultOptions": [ + { + "minimumDescriptionLength": 3, + "ts-check": false, + "ts-expect-error": "allow-with-description", + "ts-ignore": true, + "ts-nocheck": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`@ts-\` comments or require descriptions after directives", + "recommended": { + "recommended": true, + "strict": [ + { + "minimumDescriptionLength": 10, + }, + ], + }, + "url": "https://typescript-eslint.io/rules/ban-ts-comment", + }, + "hasSuggestions": true, + "messages": { + "replaceTsIgnoreWithTsExpectError": "Replace "@ts-ignore" with "@ts-expect-error".", + "tsDirectiveComment": "Do not use "@ts-{{directive}}" because it alters compilation errors.", + "tsDirectiveCommentDescriptionNotMatchPattern": "The description for the "@ts-{{directive}}" directive must match the {{format}} format.", + "tsDirectiveCommentRequiresDescription": "Include a description after the "@ts-{{directive}}" directive to explain why the @ts-{{directive}} is necessary. The description must be {{minimumDescriptionLength}} characters or longer.", + "tsIgnoreInsteadOfExpectError": "Use "@ts-expect-error" instead of "@ts-ignore", as "@ts-ignore" will do nothing if the following line is error-free.", + }, + "schema": [ + { + "$defs": { + "directiveConfigSchema": { + "oneOf": [ + { + "default": true, + "type": "boolean", + }, + { + "enum": [ + "allow-with-description", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "descriptionFormat": { + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "minimumDescriptionLength": { + "default": 3, + "type": "number", + }, + "ts-check": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-expect-error": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-ignore": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + "ts-nocheck": { + "$ref": "#/items/0/$defs/directiveConfigSchema", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "ban-tslint-comment": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow \`// tslint:\` comments", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/ban-tslint-comment", + }, + "fixable": "code", + "messages": { + "commentDetected": "tslint comment detected: "{{ text }}"", + }, + "schema": [], + "type": "suggestion", + }, + }, + "ban-types": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow certain types", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/ban-types", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "bannedTypeMessage": "Don't use \`{{name}}\` as a type.{{customMessage}}", + "bannedTypeReplacement": "Replace \`{{name}}\` with \`{{replacement}}\`.", + }, + "schema": [ + { + "$defs": { + "banConfig": { + "oneOf": [ + { + "description": "Bans the type with the default message", + "type": "null", + }, + { + "description": "Un-bans the type (useful when paired with \`extendDefaults\`)", + "enum": [ + false, + ], + "type": "boolean", + }, + { + "description": "Bans the type with the default message", + "enum": [ + true, + ], + "type": "boolean", + }, + { + "description": "Bans the type with a custom message", + "type": "string", + }, + { + "additionalProperties": false, + "description": "Bans a type", + "properties": { + "fixWith": { + "description": "Type to autofix replace with. Note that autofixers can be applied automatically - so you need to be careful with this option.", + "type": "string", + }, + "message": { + "description": "Custom error message", + "type": "string", + }, + "suggest": { + "additionalItems": false, + "description": "Types to suggest replacing with.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "extendDefaults": { + "type": "boolean", + }, + "types": { + "additionalProperties": { + "$ref": "#/items/0/$defs/banConfig", + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "block-spacing": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow or enforce spaces inside of blocks after opening block and before closing block", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/block-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "extra": "Unexpected space(s) {{location}} '{{token}}'.", + "missing": "Requires a space {{location}} '{{token}}'.", + }, + "replacedBy": [ + "@stylistic/ts/block-spacing", + ], + "schema": [ + { + "enum": [ + "always", + "never", + ], + }, + ], + "type": "layout", + }, + }, + "brace-style": { + "create": [Function], + "defaultOptions": [ + "1tbs", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent brace style for blocks", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/brace-style", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "blockSameLine": "Statement inside of curly braces should be on next line.", + "nextLineClose": "Closing curly brace does not appear on the same line as the subsequent block.", + "nextLineOpen": "Opening curly brace does not appear on the same line as controlling statement.", + "sameLineClose": "Closing curly brace appears on the same line as the subsequent block.", + "sameLineOpen": "Opening curly brace appears on the same line as controlling statement.", + "singleLineClose": "Closing curly brace should be on the same line as opening curly brace or on the line after the previous block.", + }, + "replacedBy": [ + "@stylistic/ts/brace-style", + ], + "schema": [ + { + "enum": [ + "1tbs", + "stroustrup", + "allman", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowSingleLine": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "class-literal-property-style": { + "create": [Function], + "defaultOptions": [ + "fields", + ], + "meta": { + "docs": { + "description": "Enforce that literals on classes are exposed in a consistent style", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/class-literal-property-style", + }, + "hasSuggestions": true, + "messages": { + "preferFieldStyle": "Literals should be exposed using readonly fields.", + "preferFieldStyleSuggestion": "Replace the literals with readonly fields.", + "preferGetterStyle": "Literals should be exposed using getters.", + "preferGetterStyleSuggestion": "Replace the literals with getters.", + }, + "schema": [ + { + "enum": [ + "fields", + "getters", + ], + "type": "string", + }, + ], + "type": "problem", + }, + }, + "class-methods-use-this": { + "create": [Function], + "defaultOptions": [ + { + "enforceForClassFields": true, + "exceptMethods": [], + "ignoreClassesThatImplementAnInterface": false, + "ignoreOverrideMethods": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce that class methods utilize \`this\`", + "extendsBaseRule": true, + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/class-methods-use-this", + }, + "messages": { + "missingThis": "Expected 'this' to be used by class {{name}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "enforceForClassFields": { + "default": true, + "description": "Enforces that functions used as instance field initializers utilize \`this\`", + "type": "boolean", + }, + "exceptMethods": { + "description": "Allows specified method names to be ignored with this rule", + "items": { + "type": "string", + }, + "type": "array", + }, + "ignoreClassesThatImplementAnInterface": { + "description": "Ignore classes that specifically implement some interface", + "oneOf": [ + { + "description": "Ignore all classes that implement an interface", + "type": "boolean", + }, + { + "description": "Ignore only the public fields of classes that implement an interface", + "enum": [ + "public-fields", + ], + "type": "string", + }, + ], + }, + "ignoreOverrideMethods": { + "description": "Ignore members marked with the \`override\` modifier", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "comma-dangle": { + "create": [Function], + "defaultOptions": [ + "never", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow trailing commas", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/comma-dangle", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "missing": "Missing trailing comma.", + "unexpected": "Unexpected trailing comma.", + }, + "replacedBy": [ + "@stylistic/ts/comma-dangle", + ], + "schema": { + "$defs": { + "value": { + "enum": [ + "always-multiline", + "always", + "never", + "only-multiline", + ], + "type": "string", + }, + "valueWithIgnore": { + "enum": [ + "always-multiline", + "always", + "never", + "only-multiline", + "ignore", + ], + "type": "string", + }, + }, + "additionalItems": false, + "items": [ + { + "oneOf": [ + { + "$ref": "#/$defs/value", + }, + { + "additionalProperties": false, + "properties": { + "arrays": { + "$ref": "#/$defs/valueWithIgnore", + }, + "enums": { + "$ref": "#/$defs/valueWithIgnore", + }, + "exports": { + "$ref": "#/$defs/valueWithIgnore", + }, + "functions": { + "$ref": "#/$defs/valueWithIgnore", + }, + "generics": { + "$ref": "#/$defs/valueWithIgnore", + }, + "imports": { + "$ref": "#/$defs/valueWithIgnore", + }, + "objects": { + "$ref": "#/$defs/valueWithIgnore", + }, + "tuples": { + "$ref": "#/$defs/valueWithIgnore", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "array", + }, + "type": "layout", + }, + }, + "comma-spacing": { + "create": [Function], + "defaultOptions": [ + { + "after": true, + "before": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before and after commas", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/comma-spacing", + }, + "fixable": "whitespace", + "messages": { + "missing": "A space is required {{loc}} ','.", + "unexpected": "There should be no space {{loc}} ','.", + }, + "replacedBy": [ + "@stylistic/ts/comma-spacing", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "after": { + "default": true, + "type": "boolean", + }, + "before": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "consistent-generic-constructors": { + "create": [Function], + "defaultOptions": [ + "constructor", + ], + "meta": { + "docs": { + "description": "Enforce specifying generic type arguments on type annotation or constructor name of a constructor call", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-generic-constructors", + }, + "fixable": "code", + "messages": { + "preferConstructor": "The generic type arguments should be specified as part of the constructor type arguments.", + "preferTypeAnnotation": "The generic type arguments should be specified as part of the type annotation.", + }, + "schema": [ + { + "enum": [ + "type-annotation", + "constructor", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-indexed-object-style": { + "create": [Function], + "defaultOptions": [ + "record", + ], + "meta": { + "docs": { + "description": "Require or disallow the \`Record\` type", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-indexed-object-style", + }, + "fixable": "code", + "messages": { + "preferIndexSignature": "An index signature is preferred over a record.", + "preferRecord": "A record is preferred over an index signature.", + }, + "schema": [ + { + "enum": [ + "record", + "index-signature", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-return": { + "create": [Function], + "defaultOptions": [ + { + "treatUndefinedAsUnspecified": false, + }, + ], + "meta": { + "docs": { + "description": "Require \`return\` statements to either always or never specify values", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/consistent-return", + }, + "hasSuggestions": undefined, + "messages": { + "missingReturn": "Expected to return a value at the end of {{name}}.", + "missingReturnValue": "{{name}} expected a return value.", + "unexpectedReturnValue": "{{name}} expected no return value.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "treatUndefinedAsUnspecified": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-assertions": { + "create": [Function], + "defaultOptions": [ + { + "assertionStyle": "as", + "objectLiteralTypeAssertions": "allow", + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type assertions", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-type-assertions", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "angle-bracket": "Use '<{{cast}}>' instead of 'as {{cast}}'.", + "as": "Use 'as {{cast}}' instead of '<{{cast}}>'.", + "never": "Do not use any type assertions.", + "replaceObjectTypeAssertionWithAnnotation": "Use const x: {{cast}} = { ... } instead.", + "replaceObjectTypeAssertionWithSatisfies": "Use const x = { ... } satisfies {{cast}} instead.", + "unexpectedObjectTypeAssertion": "Always prefer const x: T = { ... }.", + }, + "schema": [ + { + "oneOf": [ + { + "additionalProperties": false, + "properties": { + "assertionStyle": { + "enum": [ + "never", + ], + "type": "string", + }, + }, + "required": [ + "assertionStyle", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "assertionStyle": { + "enum": [ + "as", + "angle-bracket", + ], + "type": "string", + }, + "objectLiteralTypeAssertions": { + "enum": [ + "allow", + "allow-as-parameter", + "never", + ], + "type": "string", + }, + }, + "required": [ + "assertionStyle", + ], + "type": "object", + }, + ], + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-definitions": { + "create": [Function], + "defaultOptions": [ + "interface", + ], + "meta": { + "docs": { + "description": "Enforce type definitions to consistently use either \`interface\` or \`type\`", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/consistent-type-definitions", + }, + "fixable": "code", + "messages": { + "interfaceOverType": "Use an \`interface\` instead of a \`type\`.", + "typeOverInterface": "Use a \`type\` instead of an \`interface\`.", + }, + "schema": [ + { + "enum": [ + "interface", + "type", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-exports": { + "create": [Function], + "defaultOptions": [ + { + "fixMixedExportsWithInlineTypeSpecifier": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type exports", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/consistent-type-exports", + }, + "fixable": "code", + "messages": { + "multipleExportsAreTypes": "Type exports {{exportNames}} are not values and should be exported using \`export type\`.", + "singleExportIsType": "Type export {{exportNames}} is not a value and should be exported using \`export type\`.", + "typeOverValue": "All exports in the declaration are only used as types. Use \`export type\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "fixMixedExportsWithInlineTypeSpecifier": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "consistent-type-imports": { + "create": [Function], + "defaultOptions": [ + { + "disallowTypeAnnotations": true, + "fixStyle": "separate-type-imports", + "prefer": "type-imports", + }, + ], + "meta": { + "docs": { + "description": "Enforce consistent usage of type imports", + "url": "https://typescript-eslint.io/rules/consistent-type-imports", + }, + "fixable": "code", + "messages": { + "avoidImportType": "Use an \`import\` instead of an \`import type\`.", + "noImportTypeAnnotations": "\`import()\` type annotations are forbidden.", + "someImportsAreOnlyTypes": "Imports {{typeImports}} are only used as type.", + "typeOverValue": "All imports in the declaration are only used as types. Use \`import type\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "disallowTypeAnnotations": { + "type": "boolean", + }, + "fixStyle": { + "enum": [ + "separate-type-imports", + "inline-type-imports", + ], + "type": "string", + }, + "prefer": { + "enum": [ + "type-imports", + "no-type-imports", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "default-param-last": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce default parameters to be last", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/default-param-last", + }, + "messages": { + "shouldBeLast": "Default parameters should be last.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "dot-notation": { + "create": [Function], + "defaultOptions": [ + { + "allowIndexSignaturePropertyAccess": false, + "allowKeywords": true, + "allowPattern": "", + "allowPrivateClassPropertyAccess": false, + "allowProtectedClassPropertyAccess": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce dot notation whenever possible", + "extendsBaseRule": true, + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/dot-notation", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "useBrackets": ".{{key}} is a syntax error.", + "useDot": "[{{key}}] is better written in dot notation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowIndexSignaturePropertyAccess": { + "default": false, + "type": "boolean", + }, + "allowKeywords": { + "default": true, + "type": "boolean", + }, + "allowPattern": { + "default": "", + "type": "string", + }, + "allowPrivateClassPropertyAccess": { + "default": false, + "type": "boolean", + }, + "allowProtectedClassPropertyAccess": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "explicit-function-return-type": { + "create": [Function], + "defaultOptions": [ + { + "allowConciseArrowFunctionExpressionsStartingWithVoid": false, + "allowDirectConstAssertionInArrowFunctions": true, + "allowExpressions": false, + "allowFunctionsWithoutTypeParameters": false, + "allowHigherOrderFunctions": true, + "allowIIFEs": false, + "allowTypedFunctionExpressions": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Require explicit return types on functions and class methods", + "url": "https://typescript-eslint.io/rules/explicit-function-return-type", + }, + "messages": { + "missingReturnType": "Missing return type on function.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConciseArrowFunctionExpressionsStartingWithVoid": { + "description": "Whether to allow arrow functions that start with the \`void\` keyword.", + "type": "boolean", + }, + "allowDirectConstAssertionInArrowFunctions": { + "description": "Whether to ignore arrow functions immediately returning a \`as const\` value.", + "type": "boolean", + }, + "allowExpressions": { + "description": "Whether to ignore function expressions (functions which are not part of a declaration).", + "type": "boolean", + }, + "allowFunctionsWithoutTypeParameters": { + "description": "Whether to ignore functions that don't have generic type parameters.", + "type": "boolean", + }, + "allowHigherOrderFunctions": { + "description": "Whether to ignore functions immediately returning another function expression.", + "type": "boolean", + }, + "allowIIFEs": { + "description": "Whether to ignore immediately invoked function expressions (IIFEs).", + "type": "boolean", + }, + "allowTypedFunctionExpressions": { + "description": "Whether to ignore type annotations on the variable of function expressions.", + "type": "boolean", + }, + "allowedNames": { + "description": "An array of function/method names that will not have their arguments or return values checked.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "explicit-member-accessibility": { + "create": [Function], + "defaultOptions": [ + { + "accessibility": "explicit", + }, + ], + "meta": { + "docs": { + "description": "Require explicit accessibility modifiers on class properties and methods", + "url": "https://typescript-eslint.io/rules/explicit-member-accessibility", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "addExplicitAccessibility": "Add '{{ type }}' accessibility modifier", + "missingAccessibility": "Missing accessibility modifier on {{type}} {{name}}.", + "unwantedPublicAccessibility": "Public accessibility modifier on {{type}} {{name}}.", + }, + "schema": [ + { + "$defs": { + "accessibilityLevel": { + "oneOf": [ + { + "description": "Always require an accessor.", + "enum": [ + "explicit", + ], + "type": "string", + }, + { + "description": "Require an accessor except when public.", + "enum": [ + "no-public", + ], + "type": "string", + }, + { + "description": "Never check whether there is an accessor.", + "enum": [ + "off", + ], + "type": "string", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "accessibility": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "ignoredMethodNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "accessors": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "constructors": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "methods": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "parameterProperties": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + "properties": { + "$ref": "#/items/0/$defs/accessibilityLevel", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "explicit-module-boundary-types": { + "create": [Function], + "defaultOptions": [ + { + "allowArgumentsExplicitlyTypedAsAny": false, + "allowDirectConstAssertionInArrowFunctions": true, + "allowHigherOrderFunctions": true, + "allowTypedFunctionExpressions": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Require explicit return and argument types on exported functions' and classes' public class methods", + "url": "https://typescript-eslint.io/rules/explicit-module-boundary-types", + }, + "messages": { + "anyTypedArg": "Argument '{{name}}' should be typed with a non-any type.", + "anyTypedArgUnnamed": "{{type}} argument should be typed with a non-any type.", + "missingArgType": "Argument '{{name}}' should be typed.", + "missingArgTypeUnnamed": "{{type}} argument should be typed.", + "missingReturnType": "Missing return type on function.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowArgumentsExplicitlyTypedAsAny": { + "description": "Whether to ignore arguments that are explicitly typed as \`any\`.", + "type": "boolean", + }, + "allowDirectConstAssertionInArrowFunctions": { + "description": "Whether to ignore return type annotations on body-less arrow functions that return an \`as const\` type assertion. +You must still type the parameters of the function.", + "type": "boolean", + }, + "allowHigherOrderFunctions": { + "description": "Whether to ignore return type annotations on functions immediately returning another function expression. +You must still type the parameters of the function.", + "type": "boolean", + }, + "allowTypedFunctionExpressions": { + "description": "Whether to ignore type annotations on the variable of a function expression.", + "type": "boolean", + }, + "allowedNames": { + "description": "An array of function/method names that will not have their arguments or return values checked.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "func-call-spacing": { + "create": [Function], + "defaultOptions": [ + "never", + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow spacing between function identifiers and their invocations", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/func-call-spacing", + }, + "fixable": "whitespace", + "messages": { + "missing": "Missing space between function name and paren.", + "unexpectedNewline": "Unexpected newline between function name and paren.", + "unexpectedWhitespace": "Unexpected whitespace between function name and paren.", + }, + "replacedBy": [ + "@stylistic/ts/func-call-spacing", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "always", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowNewlines": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "indent": { + "create": [Function], + "defaultOptions": [ + 4, + { + "SwitchCase": 1, + "flatTernaryExpressions": false, + "ignoredNodes": [], + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent indentation", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/indent", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "wrongIndentation": "Expected indentation of {{expected}} but found {{actual}}.", + }, + "replacedBy": [ + "@stylistic/ts/indent", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "tab", + ], + }, + { + "minimum": 0, + "type": "integer", + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "ArrayExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "CallExpression": { + "additionalProperties": false, + "properties": { + "arguments": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "FunctionDeclaration": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + "parameters": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "FunctionExpression": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + "parameters": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + "ImportDeclaration": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "MemberExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "off", + ], + }, + ], + }, + "ObjectExpression": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "StaticBlock": { + "additionalProperties": false, + "properties": { + "body": { + "minimum": 0, + "type": "integer", + }, + }, + "type": "object", + }, + "SwitchCase": { + "default": 0, + "minimum": 0, + "type": "integer", + }, + "VariableDeclarator": { + "oneOf": [ + { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "const": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "let": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + "var": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "first", + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + ], + }, + "flatTernaryExpressions": { + "default": false, + "type": "boolean", + }, + "ignoreComments": { + "default": false, + "type": "boolean", + }, + "ignoredNodes": { + "items": { + "not": { + "pattern": ":exit$", + }, + "type": "string", + }, + "type": "array", + }, + "offsetTernaryExpressions": { + "default": false, + "type": "boolean", + }, + "outerIIFEBody": { + "oneOf": [ + { + "minimum": 0, + "type": "integer", + }, + { + "enum": [ + "off", + ], + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "init-declarations": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "docs": { + "description": "Require or disallow initialization in variable declarations", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/init-declarations", + }, + "hasSuggestions": undefined, + "messages": { + "initialized": "Variable '{{idName}}' should be initialized on declaration.", + "notInitialized": "Variable '{{idName}}' should not be initialized on declaration.", + }, + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "always", + ], + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "ignoreForLoopInit": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "suggestion", + }, + }, + "key-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing between property names and type annotations in types and interfaces", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/key-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "extraKey": "Extra space after {{computed}}key '{{key}}'.", + "extraValue": "Extra space before value for {{computed}}key '{{key}}'.", + "missingKey": "Missing space after {{computed}}key '{{key}}'.", + "missingValue": "Missing space before value for {{computed}}key '{{key}}'.", + }, + "replacedBy": [ + "@stylistic/ts/key-spacing", + ], + "schema": [ + { + "anyOf": [ + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "align": { + "anyOf": [ + { + "enum": [ + "colon", + "value", + ], + }, + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + ], + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "multiLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "align": { + "anyOf": [ + { + "enum": [ + "colon", + "value", + ], + }, + { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + ], + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + "singleLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "align": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + "on": { + "enum": [ + "colon", + "value", + ], + }, + }, + "type": "object", + }, + "multiLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + "singleLine": { + "additionalProperties": false, + "properties": { + "afterColon": { + "type": "boolean", + }, + "beforeColon": { + "type": "boolean", + }, + "mode": { + "enum": [ + "strict", + "minimum", + ], + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "keyword-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before and after keywords", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/keyword-spacing", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "expectedAfter": "Expected space(s) after "{{value}}".", + "expectedBefore": "Expected space(s) before "{{value}}".", + "unexpectedAfter": "Unexpected space(s) after "{{value}}".", + "unexpectedBefore": "Unexpected space(s) before "{{value}}".", + }, + "replacedBy": [ + "@stylistic/ts/keyword-spacing", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "after": { + "default": true, + "type": "boolean", + }, + "before": { + "default": true, + "type": "boolean", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "abstract": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "as": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "async": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "await": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "boolean": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "break": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "byte": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "case": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "catch": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "char": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "class": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "const": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "continue": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "debugger": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "default": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "delete": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "do": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "double": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "else": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "enum": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "export": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "extends": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "false": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "final": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "finally": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "float": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "for": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "from": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "function": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "get": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "goto": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "if": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "implements": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "import": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "in": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "instanceof": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "int": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "interface": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "let": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "long": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "native": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "new": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "null": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "of": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "package": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "private": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "protected": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "public": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "return": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "set": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "short": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "static": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "super": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "switch": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "synchronized": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "this": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "throw": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "throws": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "transient": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "true": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "try": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "type": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "typeof": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "var": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "void": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "volatile": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "while": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "with": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + "yield": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "lines-around-comment": { + "create": [Function], + "defaultOptions": [ + { + "beforeBlockComment": true, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require empty lines around comments", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/lines-around-comment", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "after": "Expected line after comment.", + "before": "Expected line before comment.", + }, + "replacedBy": [ + "@stylistic/ts/lines-around-comment", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "afterBlockComment": { + "default": false, + "type": "boolean", + }, + "afterLineComment": { + "default": false, + "type": "boolean", + }, + "allowArrayEnd": { + "type": "boolean", + }, + "allowArrayStart": { + "type": "boolean", + }, + "allowBlockEnd": { + "default": false, + "type": "boolean", + }, + "allowBlockStart": { + "default": false, + "type": "boolean", + }, + "allowClassEnd": { + "type": "boolean", + }, + "allowClassStart": { + "type": "boolean", + }, + "allowEnumEnd": { + "type": "boolean", + }, + "allowEnumStart": { + "type": "boolean", + }, + "allowInterfaceEnd": { + "type": "boolean", + }, + "allowInterfaceStart": { + "type": "boolean", + }, + "allowModuleEnd": { + "type": "boolean", + }, + "allowModuleStart": { + "type": "boolean", + }, + "allowObjectEnd": { + "type": "boolean", + }, + "allowObjectStart": { + "type": "boolean", + }, + "allowTypeEnd": { + "type": "boolean", + }, + "allowTypeStart": { + "type": "boolean", + }, + "applyDefaultIgnorePatterns": { + "type": "boolean", + }, + "beforeBlockComment": { + "default": true, + "type": "boolean", + }, + "beforeLineComment": { + "default": false, + "type": "boolean", + }, + "ignorePattern": { + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "lines-between-class-members": { + "create": [Function], + "defaultOptions": [ + "always", + { + "exceptAfterOverload": true, + "exceptAfterSingleLine": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow an empty line between class members", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/lines-between-class-members", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "always": "Expected blank line between class members.", + "never": "Unexpected blank line between class members.", + }, + "replacedBy": [ + "@stylistic/ts/lines-between-class-members", + ], + "schema": [ + { + "anyOf": [ + { + "additionalProperties": false, + "properties": { + "enforce": { + "items": { + "additionalProperties": false, + "properties": { + "blankLine": { + "enum": [ + "always", + "never", + ], + }, + "next": { + "enum": [ + "method", + "field", + "*", + ], + }, + "prev": { + "enum": [ + "method", + "field", + "*", + ], + }, + }, + "required": [ + "blankLine", + "prev", + "next", + ], + "type": "object", + }, + "minItems": 1, + "type": "array", + }, + }, + "required": [ + "enforce", + ], + "type": "object", + }, + { + "enum": [ + "always", + "never", + ], + }, + ], + }, + { + "additionalProperties": false, + "properties": { + "exceptAfterOverload": { + "default": true, + "type": "boolean", + }, + "exceptAfterSingleLine": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "max-params": { + "create": [Function], + "defaultOptions": [ + { + "countVoidThis": false, + "max": 3, + }, + ], + "meta": { + "docs": { + "description": "Enforce a maximum number of parameters in function definitions", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/max-params", + }, + "messages": { + "exceed": "{{name}} has too many parameters ({{count}}). Maximum allowed is {{max}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "countVoidThis": { + "type": "boolean", + }, + "max": { + "minimum": 0, + "type": "integer", + }, + "maximum": { + "minimum": 0, + "type": "integer", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "member-delimiter-style": { + "create": [Function], + "defaultOptions": [ + { + "multiline": { + "delimiter": "semi", + "requireLast": true, + }, + "multilineDetection": "brackets", + "singleline": { + "delimiter": "semi", + "requireLast": false, + }, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require a specific member delimiter style for interfaces and type literals", + "url": "https://typescript-eslint.io/rules/member-delimiter-style", + }, + "fixable": "whitespace", + "messages": { + "expectedComma": "Expected a comma.", + "expectedSemi": "Expected a semicolon.", + "unexpectedComma": "Unexpected separator (,).", + "unexpectedSemi": "Unexpected separator (;).", + }, + "replacedBy": [ + "@stylistic/ts/member-delimiter-style", + ], + "schema": [ + { + "$defs": { + "delimiterConfig": { + "additionalProperties": false, + "properties": { + "multiline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/multiLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + "singleline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/singleLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + "multiLineOption": { + "enum": [ + "none", + "semi", + "comma", + ], + "type": "string", + }, + "singleLineOption": { + "enum": [ + "semi", + "comma", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "multiline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/multiLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + "multilineDetection": { + "enum": [ + "brackets", + "last-member", + ], + "type": "string", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "interface": { + "$ref": "#/items/0/$defs/delimiterConfig", + }, + "typeLiteral": { + "$ref": "#/items/0/$defs/delimiterConfig", + }, + }, + "type": "object", + }, + "singleline": { + "additionalProperties": false, + "properties": { + "delimiter": { + "$ref": "#/items/0/$defs/singleLineOption", + }, + "requireLast": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "member-ordering": { + "create": [Function], + "defaultOptions": [ + { + "default": { + "memberTypes": [ + "signature", + "call-signature", + "public-static-field", + "protected-static-field", + "private-static-field", + "#private-static-field", + "public-decorated-field", + "protected-decorated-field", + "private-decorated-field", + "public-instance-field", + "protected-instance-field", + "private-instance-field", + "#private-instance-field", + "public-abstract-field", + "protected-abstract-field", + "public-field", + "protected-field", + "private-field", + "#private-field", + "static-field", + "instance-field", + "abstract-field", + "decorated-field", + "field", + "static-initialization", + "public-constructor", + "protected-constructor", + "private-constructor", + "constructor", + "public-static-accessor", + "protected-static-accessor", + "private-static-accessor", + "#private-static-accessor", + "public-decorated-accessor", + "protected-decorated-accessor", + "private-decorated-accessor", + "public-instance-accessor", + "protected-instance-accessor", + "private-instance-accessor", + "#private-instance-accessor", + "public-abstract-accessor", + "protected-abstract-accessor", + "public-accessor", + "protected-accessor", + "private-accessor", + "#private-accessor", + "static-accessor", + "instance-accessor", + "abstract-accessor", + "decorated-accessor", + "accessor", + "public-static-get", + "protected-static-get", + "private-static-get", + "#private-static-get", + "public-decorated-get", + "protected-decorated-get", + "private-decorated-get", + "public-instance-get", + "protected-instance-get", + "private-instance-get", + "#private-instance-get", + "public-abstract-get", + "protected-abstract-get", + "public-get", + "protected-get", + "private-get", + "#private-get", + "static-get", + "instance-get", + "abstract-get", + "decorated-get", + "get", + "public-static-set", + "protected-static-set", + "private-static-set", + "#private-static-set", + "public-decorated-set", + "protected-decorated-set", + "private-decorated-set", + "public-instance-set", + "protected-instance-set", + "private-instance-set", + "#private-instance-set", + "public-abstract-set", + "protected-abstract-set", + "public-set", + "protected-set", + "private-set", + "#private-set", + "static-set", + "instance-set", + "abstract-set", + "decorated-set", + "set", + "public-static-method", + "protected-static-method", + "private-static-method", + "#private-static-method", + "public-decorated-method", + "protected-decorated-method", + "private-decorated-method", + "public-instance-method", + "protected-instance-method", + "private-instance-method", + "#private-instance-method", + "public-abstract-method", + "protected-abstract-method", + "public-method", + "protected-method", + "private-method", + "#private-method", + "static-method", + "instance-method", + "abstract-method", + "decorated-method", + "method", + ], + }, + }, + ], + "meta": { + "docs": { + "description": "Require a consistent member declaration order", + "url": "https://typescript-eslint.io/rules/member-ordering", + }, + "messages": { + "incorrectGroupOrder": "Member {{name}} should be declared before all {{rank}} definitions.", + "incorrectOrder": "Member {{member}} should be declared before member {{beforeMember}}.", + "incorrectRequiredMembersOrder": "Member {{member}} should be declared after all {{optionalOrRequired}} members.", + }, + "schema": [ + { + "$defs": { + "allItems": { + "enum": [ + "readonly-signature", + "signature", + "readonly-field", + "public-readonly-field", + "public-decorated-readonly-field", + "decorated-readonly-field", + "static-readonly-field", + "public-static-readonly-field", + "instance-readonly-field", + "public-instance-readonly-field", + "abstract-readonly-field", + "public-abstract-readonly-field", + "protected-readonly-field", + "protected-decorated-readonly-field", + "protected-static-readonly-field", + "protected-instance-readonly-field", + "protected-abstract-readonly-field", + "private-readonly-field", + "private-decorated-readonly-field", + "private-static-readonly-field", + "private-instance-readonly-field", + "#private-readonly-field", + "#private-static-readonly-field", + "#private-instance-readonly-field", + "field", + "public-field", + "public-decorated-field", + "decorated-field", + "static-field", + "public-static-field", + "instance-field", + "public-instance-field", + "abstract-field", + "public-abstract-field", + "protected-field", + "protected-decorated-field", + "protected-static-field", + "protected-instance-field", + "protected-abstract-field", + "private-field", + "private-decorated-field", + "private-static-field", + "private-instance-field", + "#private-field", + "#private-static-field", + "#private-instance-field", + "method", + "public-method", + "public-decorated-method", + "decorated-method", + "static-method", + "public-static-method", + "instance-method", + "public-instance-method", + "abstract-method", + "public-abstract-method", + "protected-method", + "protected-decorated-method", + "protected-static-method", + "protected-instance-method", + "protected-abstract-method", + "private-method", + "private-decorated-method", + "private-static-method", + "private-instance-method", + "#private-method", + "#private-static-method", + "#private-instance-method", + "call-signature", + "constructor", + "public-constructor", + "protected-constructor", + "private-constructor", + "accessor", + "public-accessor", + "public-decorated-accessor", + "decorated-accessor", + "static-accessor", + "public-static-accessor", + "instance-accessor", + "public-instance-accessor", + "abstract-accessor", + "public-abstract-accessor", + "protected-accessor", + "protected-decorated-accessor", + "protected-static-accessor", + "protected-instance-accessor", + "protected-abstract-accessor", + "private-accessor", + "private-decorated-accessor", + "private-static-accessor", + "private-instance-accessor", + "#private-accessor", + "#private-static-accessor", + "#private-instance-accessor", + "get", + "public-get", + "public-decorated-get", + "decorated-get", + "static-get", + "public-static-get", + "instance-get", + "public-instance-get", + "abstract-get", + "public-abstract-get", + "protected-get", + "protected-decorated-get", + "protected-static-get", + "protected-instance-get", + "protected-abstract-get", + "private-get", + "private-decorated-get", + "private-static-get", + "private-instance-get", + "#private-get", + "#private-static-get", + "#private-instance-get", + "set", + "public-set", + "public-decorated-set", + "decorated-set", + "static-set", + "public-static-set", + "instance-set", + "public-instance-set", + "abstract-set", + "public-abstract-set", + "protected-set", + "protected-decorated-set", + "protected-static-set", + "protected-instance-set", + "protected-abstract-set", + "private-set", + "private-decorated-set", + "private-static-set", + "private-instance-set", + "#private-set", + "#private-static-set", + "#private-instance-set", + "static-initialization", + "static-static-initialization", + "public-static-static-initialization", + "instance-static-initialization", + "public-instance-static-initialization", + "abstract-static-initialization", + "public-abstract-static-initialization", + "protected-static-static-initialization", + "protected-instance-static-initialization", + "protected-abstract-static-initialization", + "private-static-static-initialization", + "private-instance-static-initialization", + "#private-static-static-initialization", + "#private-instance-static-initialization", + ], + "type": "string", + }, + "baseConfig": { + "oneOf": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/allItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/allItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "additionalProperties": false, + "properties": { + "memberTypes": { + "oneOf": [ + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/allItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/allItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + }, + "optionalityOrder": { + "$ref": "#/items/0/$defs/optionalityOrderOptions", + }, + "order": { + "$ref": "#/items/0/$defs/orderOptions", + }, + }, + "type": "object", + }, + ], + }, + "optionalityOrderOptions": { + "enum": [ + "optional-first", + "required-first", + ], + "type": "string", + }, + "orderOptions": { + "enum": [ + "alphabetically", + "alphabetically-case-insensitive", + "as-written", + "natural", + "natural-case-insensitive", + ], + "type": "string", + }, + "typeItems": { + "enum": [ + "readonly-signature", + "signature", + "readonly-field", + "field", + "method", + "constructor", + ], + "type": "string", + }, + "typesConfig": { + "oneOf": [ + { + "enum": [ + "never", + ], + "type": "string", + }, + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/typeItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/typeItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "additionalProperties": false, + "properties": { + "memberTypes": { + "oneOf": [ + { + "items": { + "oneOf": [ + { + "$ref": "#/items/0/$defs/typeItems", + }, + { + "items": { + "$ref": "#/items/0/$defs/typeItems", + }, + "type": "array", + }, + ], + }, + "type": "array", + }, + { + "enum": [ + "never", + ], + "type": "string", + }, + ], + }, + "optionalityOrder": { + "$ref": "#/items/0/$defs/optionalityOrderOptions", + }, + "order": { + "$ref": "#/items/0/$defs/orderOptions", + }, + }, + "type": "object", + }, + ], + }, + }, + "additionalProperties": false, + "properties": { + "classExpressions": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "classes": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "default": { + "$ref": "#/items/0/$defs/baseConfig", + }, + "interfaces": { + "$ref": "#/items/0/$defs/typesConfig", + }, + "typeLiterals": { + "$ref": "#/items/0/$defs/typesConfig", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "method-signature-style": { + "create": [Function], + "defaultOptions": [ + "property", + ], + "meta": { + "docs": { + "description": "Enforce using a particular method signature syntax", + "url": "https://typescript-eslint.io/rules/method-signature-style", + }, + "fixable": "code", + "messages": { + "errorMethod": "Shorthand method signature is forbidden. Use a function property instead.", + "errorProperty": "Function property signature is forbidden. Use a method shorthand instead.", + }, + "schema": [ + { + "enum": [ + "property", + "method", + ], + "type": "string", + }, + ], + "type": "suggestion", + }, + }, + "naming-convention": { + "create": [Function], + "defaultOptions": [ + { + "format": [ + "camelCase", + ], + "leadingUnderscore": "allow", + "selector": "default", + "trailingUnderscore": "allow", + }, + { + "format": [ + "camelCase", + "PascalCase", + ], + "selector": "import", + }, + { + "format": [ + "camelCase", + "UPPER_CASE", + ], + "leadingUnderscore": "allow", + "selector": "variable", + "trailingUnderscore": "allow", + }, + { + "format": [ + "PascalCase", + ], + "selector": "typeLike", + }, + ], + "meta": { + "docs": { + "description": "Enforce naming conventions for everything across a codebase", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/naming-convention", + }, + "messages": { + "doesNotMatchFormat": "{{type}} name \`{{name}}\` must match one of the following formats: {{formats}}", + "doesNotMatchFormatTrimmed": "{{type}} name \`{{name}}\` trimmed as \`{{processedName}}\` must match one of the following formats: {{formats}}", + "missingAffix": "{{type}} name \`{{name}}\` must have one of the following {{position}}es: {{affixes}}", + "missingUnderscore": "{{type}} name \`{{name}}\` must have {{count}} {{position}} underscore(s).", + "satisfyCustom": "{{type}} name \`{{name}}\` must {{regexMatch}} the RegExp: {{regex}}", + "unexpectedUnderscore": "{{type}} name \`{{name}}\` must not have a {{position}} underscore.", + }, + "schema": { + "$defs": { + "formatOptionsConfig": { + "oneOf": [ + { + "additionalItems": false, + "items": { + "$ref": "#/$defs/predefinedFormats", + }, + "type": "array", + }, + { + "type": "null", + }, + ], + }, + "matchRegexConfig": { + "additionalProperties": false, + "properties": { + "match": { + "type": "boolean", + }, + "regex": { + "type": "string", + }, + }, + "required": [ + "match", + "regex", + ], + "type": "object", + }, + "predefinedFormats": { + "enum": [ + "camelCase", + "strictCamelCase", + "PascalCase", + "StrictPascalCase", + "snake_case", + "UPPER_CASE", + ], + "type": "string", + }, + "prefixSuffixConfig": { + "additionalItems": false, + "items": { + "minLength": 1, + "type": "string", + }, + "type": "array", + }, + "typeModifiers": { + "enum": [ + "boolean", + "string", + "number", + "function", + "array", + ], + "type": "string", + }, + "underscoreOptions": { + "enum": [ + "forbid", + "allow", + "require", + "requireDouble", + "allowDouble", + "allowSingleOrDouble", + ], + "type": "string", + }, + }, + "additionalItems": false, + "items": { + "oneOf": [ + { + "additionalProperties": false, + "description": "Multiple selectors in one config", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "readonly", + "static", + "public", + "protected", + "private", + "#private", + "abstract", + "destructured", + "global", + "exported", + "unused", + "requiresQuotes", + "override", + "async", + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "additionalItems": false, + "items": { + "enum": [ + "default", + "variableLike", + "memberLike", + "typeLike", + "method", + "property", + "accessor", + "variable", + "function", + "parameter", + "parameterProperty", + "classicAccessor", + "enumMember", + "classMethod", + "objectLiteralMethod", + "typeMethod", + "classProperty", + "objectLiteralProperty", + "typeProperty", + "autoAccessor", + "class", + "interface", + "typeAlias", + "enum", + "typeParameter", + "import", + ], + "type": "string", + }, + "type": "array", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'default'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "readonly", + "static", + "public", + "protected", + "private", + "#private", + "abstract", + "destructured", + "global", + "exported", + "unused", + "requiresQuotes", + "override", + "async", + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "default", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'variableLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "variableLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'variable'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "const", + "destructured", + "exported", + "global", + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "variable", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'function'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "global", + "unused", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "function", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'parameter'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "destructured", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "parameter", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'memberLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "memberLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'objectLiteralProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "objectLiteralProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "readonly", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'parameterProperty'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "private", + "protected", + "public", + "readonly", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "parameterProperty", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'property'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "readonly", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "property", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'objectLiteralMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "objectLiteralMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeMethod'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "public", + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeMethod", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'method'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "#private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + "async", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "method", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'classicAccessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "classicAccessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'autoAccessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "autoAccessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'accessor'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "private", + "protected", + "public", + "requiresQuotes", + "static", + "override", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "accessor", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "types": { + "additionalItems": false, + "items": { + "$ref": "#/$defs/typeModifiers", + }, + "type": "array", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'enumMember'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "requiresQuotes", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "enumMember", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeLike'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeLike", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'class'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "abstract", + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "class", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'interface'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "interface", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeAlias'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeAlias", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'enum'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "exported", + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "enum", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'typeParameter'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "unused", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "typeParameter", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + { + "additionalProperties": false, + "description": "Selector 'import'", + "properties": { + "custom": { + "$ref": "#/$defs/matchRegexConfig", + }, + "failureMessage": { + "type": "string", + }, + "filter": { + "oneOf": [ + { + "minLength": 1, + "type": "string", + }, + { + "$ref": "#/$defs/matchRegexConfig", + }, + ], + }, + "format": { + "$ref": "#/$defs/formatOptionsConfig", + }, + "leadingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + "modifiers": { + "additionalItems": false, + "items": { + "enum": [ + "default", + "namespace", + ], + "type": "string", + }, + "type": "array", + }, + "prefix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "selector": { + "enum": [ + "import", + ], + "type": "string", + }, + "suffix": { + "$ref": "#/$defs/prefixSuffixConfig", + }, + "trailingUnderscore": { + "$ref": "#/$defs/underscoreOptions", + }, + }, + "required": [ + "selector", + "format", + ], + "type": "object", + }, + ], + }, + "type": "array", + }, + "type": "suggestion", + }, + }, + "no-array-constructor": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow generic \`Array\` constructors", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-array-constructor", + }, + "fixable": "code", + "messages": { + "useLiteral": "The array literal notation [] is preferable.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-array-delete": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow using the \`delete\` operator on array values", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-array-delete", + }, + "hasSuggestions": true, + "messages": { + "noArrayDelete": "Using the \`delete\` operator with an array expression is unsafe.", + "useSplice": "Use \`array.splice()\` instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-base-to-string": { + "create": [Function], + "defaultOptions": [ + { + "ignoredTypeNames": [ + "Error", + "RegExp", + "URL", + "URLSearchParams", + ], + }, + ], + "meta": { + "docs": { + "description": "Require \`.toString()\` to only be called on objects which provide useful information when stringified", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-base-to-string", + }, + "messages": { + "baseToString": "'{{name}}' {{certainty}} evaluate to '[object Object]' when stringified.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoredTypeNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-confusing-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertion in locations that may be confusing", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-confusing-non-null-assertion", + }, + "hasSuggestions": true, + "messages": { + "confusingAssign": "Confusing combinations of non-null assertion and equal test like "a! = b", which looks very similar to not equal "a != b".", + "confusingEqual": "Confusing combinations of non-null assertion and equal test like "a! == b", which looks very similar to not equal "a !== b".", + "notNeedInAssign": "Unnecessary non-null assertion (!) in assignment left hand.", + "notNeedInEqualTest": "Unnecessary non-null assertion (!) in equal test.", + "wrapUpLeft": "Wrap up left hand to avoid putting non-null assertion "!" and "=" together.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-confusing-void-expression": { + "create": [Function], + "defaultOptions": [ + { + "ignoreArrowShorthand": false, + "ignoreVoidOperator": false, + }, + ], + "meta": { + "docs": { + "description": "Require expressions of type void to appear in statement position", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-confusing-void-expression", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "invalidVoidExpr": "Placing a void expression inside another expression is forbidden. Move it to its own statement instead.", + "invalidVoidExprArrow": "Returning a void expression from an arrow function shorthand is forbidden. Please add braces to the arrow function.", + "invalidVoidExprArrowWrapVoid": "Void expressions returned from an arrow function shorthand must be marked explicitly with the \`void\` operator.", + "invalidVoidExprReturn": "Returning a void expression from a function is forbidden. Please move it before the \`return\` statement.", + "invalidVoidExprReturnLast": "Returning a void expression from a function is forbidden. Please remove the \`return\` statement.", + "invalidVoidExprReturnWrapVoid": "Void expressions returned from a function must be marked explicitly with the \`void\` operator.", + "invalidVoidExprWrapVoid": "Void expressions used inside another expression must be moved to its own statement or marked explicitly with the \`void\` operator.", + "voidExprWrapVoid": "Mark with an explicit \`void\` operator.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreArrowShorthand": { + "type": "boolean", + }, + "ignoreVoidOperator": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-dupe-class-members": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow duplicate class members", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-dupe-class-members", + }, + "hasSuggestions": undefined, + "messages": { + "unexpected": "Duplicate name '{{name}}'.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-duplicate-enum-values": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow duplicate enum member values", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-duplicate-enum-values", + }, + "hasSuggestions": false, + "messages": { + "duplicateValue": "Duplicate enum member value {{value}}.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-duplicate-type-constituents": { + "create": [Function], + "defaultOptions": [ + { + "ignoreIntersections": false, + "ignoreUnions": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow duplicate constituents of union or intersection types", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-duplicate-type-constituents", + }, + "fixable": "code", + "messages": { + "duplicate": "{{type}} type constituent is duplicated with {{previous}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreIntersections": { + "type": "boolean", + }, + "ignoreUnions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-dynamic-delete": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow using the \`delete\` operator on computed key expressions", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-dynamic-delete", + }, + "fixable": "code", + "messages": { + "dynamicDelete": "Do not delete dynamically computed property keys.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-empty-function": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow empty functions", + "extendsBaseRule": true, + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-empty-function", + }, + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unexpected empty {{name}}.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "enum": [ + "functions", + "arrowFunctions", + "generatorFunctions", + "methods", + "generatorMethods", + "getters", + "setters", + "constructors", + "private-constructors", + "protected-constructors", + "asyncFunctions", + "asyncMethods", + "decoratedFunctions", + "overrideMethods", + ], + "type": "string", + }, + "type": "array", + "uniqueItems": true, + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-empty-interface": { + "create": [Function], + "defaultOptions": [ + { + "allowSingleExtends": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the declaration of empty interfaces", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-empty-interface", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "noEmpty": "An empty interface is equivalent to \`{}\`.", + "noEmptyWithSuper": "An interface declaring no members is equivalent to its supertype.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowSingleExtends": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-explicit-any": { + "create": [Function], + "defaultOptions": [ + { + "fixToUnknown": false, + "ignoreRestArgs": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the \`any\` type", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-explicit-any", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "suggestNever": "Use \`never\` instead, this is useful when instantiating generic type parameters that you don't need to know the type of.", + "suggestUnknown": "Use \`unknown\` instead, this will force you to explicitly, and safely assert the type is correct.", + "unexpectedAny": "Unexpected any. Specify a different type.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "fixToUnknown": { + "description": "Whether to enable auto-fixing in which the \`any\` type is converted to the \`unknown\` type.", + "type": "boolean", + }, + "ignoreRestArgs": { + "description": "Whether to ignore rest parameter arrays.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-extra-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow extra non-null assertions", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-extra-non-null-assertion", + }, + "fixable": "code", + "messages": { + "noExtraNonNullAssertion": "Forbidden extra non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-extra-parens": { + "create": [Function], + "defaultOptions": [ + "all", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow unnecessary parentheses", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-extra-parens", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unnecessary parentheses around expression.", + }, + "replacedBy": [ + "@stylistic/ts/no-extra-parens", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "functions", + ], + }, + ], + "maxItems": 1, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "all", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowParensAfterCommentPattern": { + "type": "string", + }, + "conditionalAssign": { + "type": "boolean", + }, + "enforceForArrowConditionals": { + "type": "boolean", + }, + "enforceForFunctionPrototypeMethods": { + "type": "boolean", + }, + "enforceForNewInMemberExpressions": { + "type": "boolean", + }, + "enforceForSequenceExpressions": { + "type": "boolean", + }, + "ignoreJSX": { + "enum": [ + "none", + "all", + "single-line", + "multi-line", + ], + }, + "nestedBinaryExpressions": { + "type": "boolean", + }, + "returnAssign": { + "type": "boolean", + }, + "ternaryOperandBinaryExpressions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "no-extra-semi": { + "create": [Function], + "defaultOptions": [], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow unnecessary semicolons", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-extra-semi", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "unexpected": "Unnecessary semicolon.", + }, + "replacedBy": [ + "@stylistic/ts/no-extra-semi", + ], + "schema": [], + "type": "suggestion", + }, + }, + "no-extraneous-class": { + "create": [Function], + "defaultOptions": [ + { + "allowConstructorOnly": false, + "allowEmpty": false, + "allowStaticOnly": false, + "allowWithDecorator": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow classes used as namespaces", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-extraneous-class", + }, + "messages": { + "empty": "Unexpected empty class.", + "onlyConstructor": "Unexpected class with only a constructor.", + "onlyStatic": "Unexpected class with only static properties.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConstructorOnly": { + "description": "Whether to allow extraneous classes that contain only a constructor.", + "type": "boolean", + }, + "allowEmpty": { + "description": "Whether to allow extraneous classes that have no body (i.e. are empty).", + "type": "boolean", + }, + "allowStaticOnly": { + "description": "Whether to allow extraneous classes that only contain static members.", + "type": "boolean", + }, + "allowWithDecorator": { + "description": "Whether to allow extraneous classes that include a decorator.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-floating-promises": { + "create": [Function], + "defaultOptions": [ + { + "ignoreIIFE": false, + "ignoreVoid": true, + }, + ], + "meta": { + "docs": { + "description": "Require Promise-like statements to be handled appropriately", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-floating-promises", + }, + "hasSuggestions": true, + "messages": { + "floating": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler.", + "floatingFixAwait": "Add await operator.", + "floatingFixVoid": "Add void operator to ignore.", + "floatingPromiseArray": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar.", + "floatingPromiseArrayVoid": "An array of Promises may be unintentional. Consider handling the promises' fulfillment or rejection with Promise.all or similar, or explicitly marking the expression as ignored with the \`void\` operator.", + "floatingUselessRejectionHandler": "Promises must be awaited, end with a call to .catch, or end with a call to .then with a rejection handler. A rejection handler that is not a function will be ignored.", + "floatingUselessRejectionHandlerVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator. A rejection handler that is not a function will be ignored.", + "floatingVoid": "Promises must be awaited, end with a call to .catch, end with a call to .then with a rejection handler or be explicitly marked as ignored with the \`void\` operator.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreIIFE": { + "description": "Whether to ignore async IIFEs (Immediately Invoked Function Expressions).", + "type": "boolean", + }, + "ignoreVoid": { + "description": "Whether to ignore \`void\` expressions.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-for-in-array": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow iterating over an array with a for-in loop", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-for-in-array", + }, + "messages": { + "forInViolation": "For-in loops over arrays skips holes, returns indices as strings, and may visit the prototype chain or other enumerable properties. Use a more robust iteration method such as for-of or array.forEach instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-implied-eval": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow the use of \`eval()\`-like methods", + "extendsBaseRule": true, + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-implied-eval", + }, + "messages": { + "noFunctionConstructor": "Implied eval. Do not use the Function constructor to create functions.", + "noImpliedEvalError": "Implied eval. Consider passing a function.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-import-type-side-effects": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of top-level import type qualifier when an import only has specifiers with inline type qualifiers", + "url": "https://typescript-eslint.io/rules/no-import-type-side-effects", + }, + "fixable": "code", + "messages": { + "useTopLevelQualifier": "TypeScript will only remove the inline type specifiers which will leave behind a side effect import at runtime. Convert this to a top-level type qualifier to properly remove the entire import.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-inferrable-types": { + "create": [Function], + "defaultOptions": [ + { + "ignoreParameters": false, + "ignoreProperties": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow explicit type declarations for variables or parameters initialized to a number, string, or boolean", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/no-inferrable-types", + }, + "fixable": "code", + "messages": { + "noInferrableType": "Type {{type}} trivially inferred from a {{type}} literal, remove type annotation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreParameters": { + "type": "boolean", + }, + "ignoreProperties": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-invalid-this": { + "create": [Function], + "defaultOptions": [ + { + "capIsConstructor": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`this\` keywords outside of classes or class-like objects", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-invalid-this", + }, + "hasSuggestions": undefined, + "messages": { + "unexpectedThis": "Unexpected 'this'.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "capIsConstructor": { + "default": true, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-invalid-void-type": { + "create": [Function], + "defaultOptions": [ + { + "allowAsThisParameter": false, + "allowInGenericTypeArguments": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow \`void\` type outside of generic or return types", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-invalid-void-type", + }, + "messages": { + "invalidVoidForGeneric": "{{ generic }} may not have void as a type argument.", + "invalidVoidNotReturn": "void is only valid as a return type.", + "invalidVoidNotReturnOrGeneric": "void is only valid as a return type or generic type argument.", + "invalidVoidNotReturnOrThisParam": "void is only valid as return type or type of \`this\` parameter.", + "invalidVoidNotReturnOrThisParamOrGeneric": "void is only valid as a return type or generic type argument or the type of a \`this\` parameter.", + "invalidVoidUnionConstituent": "void is not valid as a constituent in a union type", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAsThisParameter": { + "type": "boolean", + }, + "allowInGenericTypeArguments": { + "oneOf": [ + { + "type": "boolean", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-loop-func": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow function declarations that contain unsafe references inside loop statements", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-loop-func", + }, + "hasSuggestions": undefined, + "messages": { + "unsafeRefs": "Function declared in a loop contains unsafe references to variable(s) {{ varNames }}.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-loss-of-precision": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow literal numbers that lose precision", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-loss-of-precision", + }, + "hasSuggestions": undefined, + "messages": { + "noLossOfPrecision": "This number literal will lose precision at runtime.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-magic-numbers": { + "create": [Function], + "defaultOptions": [ + { + "detectObjects": false, + "enforceConst": false, + "ignore": [], + "ignoreArrayIndexes": false, + "ignoreEnums": false, + "ignoreNumericLiteralTypes": false, + "ignoreReadonlyClassProperties": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow magic numbers", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-magic-numbers", + }, + "messages": { + "noMagic": "No magic number: {{raw}}.", + "useConst": "Number constants declarations must use 'const'.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "detectObjects": { + "default": false, + "type": "boolean", + }, + "enforceConst": { + "default": false, + "type": "boolean", + }, + "ignore": { + "items": { + "anyOf": [ + { + "type": "number", + }, + { + "pattern": "^[+-]?(?:0|[1-9][0-9]*)n$", + "type": "string", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + "ignoreArrayIndexes": { + "default": false, + "type": "boolean", + }, + "ignoreClassFieldInitialValues": { + "default": false, + "type": "boolean", + }, + "ignoreDefaultValues": { + "default": false, + "type": "boolean", + }, + "ignoreEnums": { + "type": "boolean", + }, + "ignoreNumericLiteralTypes": { + "type": "boolean", + }, + "ignoreReadonlyClassProperties": { + "type": "boolean", + }, + "ignoreTypeIndexes": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-meaningless-void-operator": { + "create": [Function], + "defaultOptions": [ + { + "checkNever": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow the \`void\` operator except when used to discard a value", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-meaningless-void-operator", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "meaninglessVoidOperator": "void operator shouldn't be used on {{type}}; it should convey that a return value is being ignored", + "removeVoid": "Remove 'void'", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checkNever": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-misused-new": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce valid definition of \`new\` and \`constructor\`", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-misused-new", + }, + "messages": { + "errorMessageClass": "Class cannot have method named \`new\`.", + "errorMessageInterface": "Interfaces cannot be constructed, only classes.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-misused-promises": { + "create": [Function], + "defaultOptions": [ + { + "checksConditionals": true, + "checksSpreads": true, + "checksVoidReturn": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow Promises in places not designed to handle them", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-misused-promises", + }, + "messages": { + "conditional": "Expected non-Promise value in a boolean conditional.", + "spread": "Expected a non-Promise value to be spreaded in an object.", + "voidReturnArgument": "Promise returned in function argument where a void return was expected.", + "voidReturnAttribute": "Promise-returning function provided to attribute where a void return was expected.", + "voidReturnProperty": "Promise-returning function provided to property where a void return was expected.", + "voidReturnReturnValue": "Promise-returning function provided to return value where a void return was expected.", + "voidReturnVariable": "Promise-returning function provided to variable where a void return was expected.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checksConditionals": { + "type": "boolean", + }, + "checksSpreads": { + "type": "boolean", + }, + "checksVoidReturn": { + "oneOf": [ + { + "type": "boolean", + }, + { + "additionalProperties": false, + "properties": { + "arguments": { + "type": "boolean", + }, + "attributes": { + "type": "boolean", + }, + "properties": { + "type": "boolean", + }, + "returns": { + "type": "boolean", + }, + "variables": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-mixed-enums": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow enums from having both number and string members", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-mixed-enums", + }, + "messages": { + "mixed": "Mixing number and string enums can be confusing.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-namespace": { + "create": [Function], + "defaultOptions": [ + { + "allowDeclarations": false, + "allowDefinitionFiles": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow TypeScript namespaces", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-namespace", + }, + "messages": { + "moduleSyntaxIsPreferred": "ES2015 module syntax is preferred over namespaces.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDeclarations": { + "description": "Whether to allow \`declare\` with custom TypeScript namespaces.", + "type": "boolean", + }, + "allowDefinitionFiles": { + "description": "Whether to allow \`declare\` with custom TypeScript namespaces inside definition files.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-non-null-asserted-nullish-coalescing": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions in the left operand of a nullish coalescing operator", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-non-null-asserted-nullish-coalescing", + }, + "hasSuggestions": true, + "messages": { + "noNonNullAssertedNullishCoalescing": "The nullish coalescing operator is designed to handle undefined and null - using a non-null assertion is not needed.", + "suggestRemovingNonNull": "Remove the non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-non-null-asserted-optional-chain": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions after an optional chain expression", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-non-null-asserted-optional-chain", + }, + "hasSuggestions": true, + "messages": { + "noNonNullOptionalChain": "Optional chain expressions can return undefined by design - using a non-null assertion is unsafe and wrong.", + "suggestRemovingNonNull": "You should remove the non-null assertion.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-non-null-assertion": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow non-null assertions using the \`!\` postfix operator", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-non-null-assertion", + }, + "hasSuggestions": true, + "messages": { + "noNonNull": "Forbidden non-null assertion.", + "suggestOptionalChain": "Consider using the optional chain operator \`?.\` instead. This operator includes runtime checks, so it is safer than the compile-only non-null assertion operator.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-redeclare": { + "create": [Function], + "defaultOptions": [ + { + "builtinGlobals": true, + "ignoreDeclarationMerge": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow variable redeclaration", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-redeclare", + }, + "messages": { + "redeclared": "'{{id}}' is already defined.", + "redeclaredAsBuiltin": "'{{id}}' is already defined as a built-in global variable.", + "redeclaredBySyntax": "'{{id}}' is already defined by a variable declaration.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "builtinGlobals": { + "type": "boolean", + }, + "ignoreDeclarationMerge": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-redundant-type-constituents": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow members of unions and intersections that do nothing or override type information", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-redundant-type-constituents", + }, + "messages": { + "literalOverridden": "{{literal}} is overridden by {{primitive}} in this union type.", + "overridden": "'{{typeName}}' is overridden by other types in this {{container}} type.", + "overrides": "'{{typeName}}' overrides all other types in this {{container}} type.", + "primitiveOverridden": "{{primitive}} is overridden by the {{literal}} in this intersection type.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-require-imports": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow invocation of \`require()\`", + "url": "https://typescript-eslint.io/rules/no-require-imports", + }, + "messages": { + "noRequireImports": "A \`require()\` style import is forbidden.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "description": "Patterns of import paths to allow requiring from.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-restricted-imports": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow specified modules when loaded by \`import\`", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-restricted-imports", + }, + "fixable": undefined, + "messages": { + "everything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted.", + "everythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted. {{customMessage}}", + "importName": "'{{importName}}' import from '{{importSource}}' is restricted.", + "importNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted. {{customMessage}}", + "path": "'{{importSource}}' import is restricted from being used.", + "pathWithCustomMessage": "'{{importSource}}' import is restricted from being used. {{customMessage}}", + "patternAndEverything": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern.", + "patternAndEverythingWithCustomMessage": "* import is invalid because '{{importNames}}' from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", + "patternAndEverythingWithRegexImportName": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used.", + "patternAndEverythingWithRegexImportNameAndCustomMessage": "* import is invalid because import name matching '{{importNames}}' pattern from '{{importSource}}' is restricted from being used. {{customMessage}}", + "patternAndImportName": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern.", + "patternAndImportNameWithCustomMessage": "'{{importName}}' import from '{{importSource}}' is restricted from being used by a pattern. {{customMessage}}", + "patternWithCustomMessage": "'{{importSource}}' import is restricted from being used by a pattern. {{customMessage}}", + "patterns": "'{{importSource}}' import is restricted from being used by a pattern.", + }, + "schema": { + "anyOf": [ + { + "items": { + "anyOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "importNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "message": { + "minLength": 1, + "type": "string", + }, + "name": { + "type": "string", + }, + }, + "required": [ + "name", + ], + "type": "object", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + { + "additionalItems": false, + "items": [ + { + "additionalProperties": false, + "properties": { + "paths": { + "items": { + "anyOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "importNames": { + "items": { + "type": "string", + }, + "type": "array", + }, + "message": { + "minLength": 1, + "type": "string", + }, + "name": { + "type": "string", + }, + }, + "required": [ + "name", + ], + "type": "object", + }, + ], + }, + "type": "array", + "uniqueItems": true, + }, + "patterns": { + "anyOf": [ + { + "items": { + "type": "string", + }, + "type": "array", + "uniqueItems": true, + }, + { + "items": { + "additionalProperties": false, + "properties": { + "allowTypeImports": { + "description": "Disallow value imports, but allow type-only imports.", + "type": "boolean", + }, + "caseSensitive": { + "type": "boolean", + }, + "group": { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + "importNamePattern": { + "type": "string", + }, + "importNames": { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + "message": { + "minLength": 1, + "type": "string", + }, + }, + "required": [ + "group", + ], + "type": "object", + }, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "type": "object", + }, + ], + "type": "array", + }, + ], + }, + "type": "suggestion", + }, + }, + "no-shadow": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "builtinGlobals": false, + "hoist": "functions", + "ignoreFunctionTypeParameterNameValueShadow": true, + "ignoreOnInitialization": false, + "ignoreTypeValueShadow": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow variable declarations from shadowing variables declared in the outer scope", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-shadow", + }, + "messages": { + "noShadow": "'{{name}}' is already declared in the upper scope on line {{shadowedLine}} column {{shadowedColumn}}.", + "noShadowGlobal": "'{{name}}' is already a global variable.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "type": "string", + }, + "type": "array", + }, + "builtinGlobals": { + "type": "boolean", + }, + "hoist": { + "enum": [ + "all", + "functions", + "never", + ], + "type": "string", + }, + "ignoreFunctionTypeParameterNameValueShadow": { + "type": "boolean", + }, + "ignoreOnInitialization": { + "type": "boolean", + }, + "ignoreTypeValueShadow": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-this-alias": { + "create": [Function], + "defaultOptions": [ + { + "allowDestructuring": true, + "allowedNames": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow aliasing \`this\`", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-this-alias", + }, + "messages": { + "thisAssignment": "Unexpected aliasing of 'this' to local variable.", + "thisDestructure": "Unexpected aliasing of members of 'this' to local variables.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDestructuring": { + "description": "Whether to ignore destructurings, such as \`const { props, state } = this\`.", + "type": "boolean", + }, + "allowedNames": { + "description": "Names to ignore, such as ["self"] for \`const self = this;\`.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-throw-literal": { + "create": [Function], + "defaultOptions": [ + { + "allowThrowingAny": true, + "allowThrowingUnknown": true, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow throwing literals as exceptions", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-throw-literal", + }, + "messages": { + "object": "Expected an error object to be thrown.", + "undef": "Do not throw undefined.", + }, + "replacedBy": [ + "@typescript-eslint/only-throw-error", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowThrowingAny": { + "type": "boolean", + }, + "allowThrowingUnknown": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "no-type-alias": { + "create": [Function], + "defaultOptions": [ + { + "allowAliases": "never", + "allowCallbacks": "never", + "allowConditionalTypes": "never", + "allowConstructors": "never", + "allowGenerics": "never", + "allowLiterals": "never", + "allowMappedTypes": "never", + "allowTupleTypes": "never", + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Disallow type aliases", + "url": "https://typescript-eslint.io/rules/no-type-alias", + }, + "messages": { + "noCompositionAlias": "{{typeName}} in {{compositionType}} types are not allowed.", + "noTypeAlias": "Type {{alias}} are not allowed.", + }, + "schema": [ + { + "$defs": { + "expandedOptions": { + "enum": [ + "always", + "never", + "in-unions", + "in-intersections", + "in-unions-and-intersections", + ], + "type": "string", + }, + "simpleOptions": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "allowAliases": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow direct one-to-one type aliases.", + }, + "allowCallbacks": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases for callbacks.", + }, + "allowConditionalTypes": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases for conditional types.", + }, + "allowConstructors": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases with constructors.", + }, + "allowGenerics": { + "$ref": "#/items/0/$defs/simpleOptions", + "description": "Whether to allow type aliases with generic types.", + }, + "allowLiterals": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with object literal types.", + }, + "allowMappedTypes": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with mapped types.", + }, + "allowTupleTypes": { + "$ref": "#/items/0/$defs/expandedOptions", + "description": "Whether to allow type aliases with tuple types.", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-boolean-literal-compare": { + "create": [Function], + "defaultOptions": [ + { + "allowComparingNullableBooleansToFalse": true, + "allowComparingNullableBooleansToTrue": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow unnecessary equality comparisons against boolean literals", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-boolean-literal-compare", + }, + "fixable": "code", + "messages": { + "comparingNullableToFalse": "This expression unnecessarily compares a nullable boolean value to false instead of using the ?? operator to provide a default.", + "comparingNullableToTrueDirect": "This expression unnecessarily compares a nullable boolean value to true instead of using it directly.", + "comparingNullableToTrueNegated": "This expression unnecessarily compares a nullable boolean value to true instead of negating it.", + "direct": "This expression unnecessarily compares a boolean value to a boolean instead of using it directly.", + "negated": "This expression unnecessarily compares a boolean value to a boolean instead of negating it.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowComparingNullableBooleansToFalse": { + "description": "Whether to allow comparisons between nullable boolean variables and \`false\`.", + "type": "boolean", + }, + "allowComparingNullableBooleansToTrue": { + "description": "Whether to allow comparisons between nullable boolean variables and \`true\`.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-condition": { + "create": [Function], + "defaultOptions": [ + { + "allowConstantLoopConditions": false, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow conditionals where the type is always truthy or always falsy", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-condition", + }, + "fixable": "code", + "messages": { + "alwaysFalsy": "Unnecessary conditional, value is always falsy.", + "alwaysFalsyFunc": "This callback should return a conditional, but return is always falsy.", + "alwaysNullish": "Unnecessary conditional, left-hand side of \`??\` operator is always \`null\` or \`undefined\`.", + "alwaysTruthy": "Unnecessary conditional, value is always truthy.", + "alwaysTruthyFunc": "This callback should return a conditional, but return is always truthy.", + "literalBooleanExpression": "Unnecessary conditional, both sides of the expression are literal values.", + "never": "Unnecessary conditional, value is \`never\`.", + "neverNullish": "Unnecessary conditional, expected left-hand side of \`??\` operator to be possibly null or undefined.", + "neverOptionalChain": "Unnecessary optional chain on a non-nullish value.", + "noOverlapBooleanExpression": "Unnecessary conditional, the types have no overlap.", + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowConstantLoopConditions": { + "description": "Whether to ignore constant loop conditions, such as \`while (true)\`.", + "type": "boolean", + }, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "description": "Whether to not error when running with a tsconfig that has strictNullChecks turned.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-qualifier": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary namespace qualifiers", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-qualifier", + }, + "fixable": "code", + "messages": { + "unnecessaryQualifier": "Qualifier is unnecessary since '{{ name }}' is in scope.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unnecessary-type-arguments": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow type arguments that are equal to the default", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-arguments", + }, + "fixable": "code", + "messages": { + "unnecessaryTypeParameter": "This is the default value for this type parameter, so it can be omitted.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unnecessary-type-assertion": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow type assertions that do not change the type of an expression", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-assertion", + }, + "fixable": "code", + "messages": { + "contextuallyUnnecessary": "This assertion is unnecessary since the receiver accepts the original type of the expression.", + "unnecessaryAssertion": "This assertion is unnecessary since it does not change the type of the expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "typesToIgnore": { + "description": "A list of type names to ignore.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unnecessary-type-constraint": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary constraints on generic types", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-unnecessary-type-constraint", + }, + "hasSuggestions": true, + "messages": { + "removeUnnecessaryConstraint": "Remove the unnecessary \`{{constraint}}\` constraint.", + "unnecessaryConstraint": "Constraining the generic type \`{{name}}\` to \`{{constraint}}\` does nothing and is unnecessary.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unsafe-argument": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow calling a function with a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-argument", + }, + "messages": { + "unsafeArgument": "Unsafe argument of type \`{{sender}}\` assigned to a parameter of type \`{{receiver}}\`.", + "unsafeArraySpread": "Unsafe spread of an \`any\` array type.", + "unsafeSpread": "Unsafe spread of an \`any\` type.", + "unsafeTupleSpread": "Unsafe spread of a tuple type. The argument is of type \`{{sender}}\` and is assigned to a parameter of type \`{{receiver}}\`.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-assignment": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow assigning a value with type \`any\` to variables and properties", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-assignment", + }, + "messages": { + "anyAssignment": "Unsafe assignment of an \`any\` value.", + "anyAssignmentThis": "Unsafe assignment of an \`any\` value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + "unsafeArrayPattern": "Unsafe array destructuring of an \`any\` array value.", + "unsafeArrayPatternFromTuple": "Unsafe array destructuring of a tuple element with an \`any\` value.", + "unsafeArraySpread": "Unsafe spread of an \`any\` value in an array.", + "unsafeAssignment": "Unsafe assignment of type {{sender}} to a variable of type {{receiver}}.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-call": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow calling a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-call", + }, + "messages": { + "unsafeCall": "Unsafe call of an \`any\` typed value.", + "unsafeCallThis": "Unsafe call of an \`any\` typed value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + "unsafeNew": "Unsafe construction of an any type value.", + "unsafeTemplateTag": "Unsafe any typed template tag.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-declaration-merging": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unsafe declaration merging", + "recommended": "recommended", + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/no-unsafe-declaration-merging", + }, + "messages": { + "unsafeMerging": "Unsafe declaration merging between classes and interfaces.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-enum-comparison": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow comparing an enum value with a non-enum value", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-enum-comparison", + }, + "hasSuggestions": true, + "messages": { + "mismatchedCase": "The case statement does not have a shared enum type with the switch predicate.", + "mismatchedCondition": "The two values in this comparison do not have a shared enum type.", + "replaceValueWithEnum": "Replace with an enum value comparison.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-unsafe-member-access": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow member access on a value with type \`any\`", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-member-access", + }, + "messages": { + "unsafeComputedMemberAccess": "Computed name {{property}} resolves to an any value.", + "unsafeMemberExpression": "Unsafe member access {{property}} on an \`any\` value.", + "unsafeThisMemberExpression": "Unsafe member access {{property}} on an \`any\` value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-return": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow returning a value with type \`any\` from a function", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-return", + }, + "messages": { + "unsafeReturn": "Unsafe return of an \`{{type}}\` typed value.", + "unsafeReturnAssignment": "Unsafe return of type \`{{sender}}\` from function with return type \`{{receiver}}\`.", + "unsafeReturnThis": "Unsafe return of an \`{{type}}\` typed value. \`this\` is typed as \`any\`. +You can try to fix this by turning on the \`noImplicitThis\` compiler option, or adding a \`this\` parameter to the function.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unsafe-unary-minus": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require unary negation to take a number", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-unsafe-unary-minus", + }, + "messages": { + "unaryMinus": "Argument of unary negation should be assignable to number | bigint but is {{type}} instead.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-unused-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowShortCircuit": false, + "allowTaggedTemplates": false, + "allowTernary": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow unused expressions", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-unused-expressions", + }, + "hasSuggestions": undefined, + "messages": { + "unusedExpression": "Expected an assignment or function call and instead saw an expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowShortCircuit": { + "default": false, + "type": "boolean", + }, + "allowTaggedTemplates": { + "default": false, + "type": "boolean", + }, + "allowTernary": { + "default": false, + "type": "boolean", + }, + "enforceForJSX": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "no-unused-vars": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "docs": { + "description": "Disallow unused variables", + "extendsBaseRule": true, + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-unused-vars", + }, + "messages": { + "unusedVar": "'{{varName}}' is {{action}} but never used{{additional}}.", + }, + "schema": [ + { + "oneOf": [ + { + "enum": [ + "all", + "local", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "args": { + "enum": [ + "all", + "after-used", + "none", + ], + "type": "string", + }, + "argsIgnorePattern": { + "type": "string", + }, + "caughtErrors": { + "enum": [ + "all", + "none", + ], + "type": "string", + }, + "caughtErrorsIgnorePattern": { + "type": "string", + }, + "destructuredArrayIgnorePattern": { + "type": "string", + }, + "ignoreRestSiblings": { + "type": "boolean", + }, + "vars": { + "enum": [ + "all", + "local", + ], + "type": "string", + }, + "varsIgnorePattern": { + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "problem", + }, + }, + "no-use-before-define": { + "create": [Function], + "defaultOptions": [ + { + "allowNamedExports": false, + "classes": true, + "enums": true, + "functions": true, + "ignoreTypeReferences": true, + "typedefs": true, + "variables": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow the use of variables before they are defined", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/no-use-before-define", + }, + "messages": { + "noUseBeforeDefine": "'{{name}}' was used before it was defined.", + }, + "schema": [ + { + "oneOf": [ + { + "enum": [ + "nofunc", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "allowNamedExports": { + "type": "boolean", + }, + "classes": { + "type": "boolean", + }, + "enums": { + "type": "boolean", + }, + "functions": { + "type": "boolean", + }, + "ignoreTypeReferences": { + "type": "boolean", + }, + "typedefs": { + "type": "boolean", + }, + "variables": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "problem", + }, + }, + "no-useless-constructor": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary constructors", + "extendsBaseRule": true, + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/no-useless-constructor", + }, + "hasSuggestions": undefined, + "messages": { + "noUselessConstructor": "Useless constructor.", + }, + "schema": [], + "type": "problem", + }, + }, + "no-useless-empty-export": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow empty exports that don't change anything in a module file", + "url": "https://typescript-eslint.io/rules/no-useless-empty-export", + }, + "fixable": "code", + "hasSuggestions": false, + "messages": { + "uselessExport": "Empty export does nothing and can be removed.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-useless-template-literals": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow unnecessary template literals", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/no-useless-template-literals", + }, + "fixable": "code", + "messages": { + "noUselessTemplateLiteral": "Template literal expression is unnecessary and can be simplified.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "no-var-requires": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + }, + ], + "meta": { + "docs": { + "description": "Disallow \`require\` statements except in import statements", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/no-var-requires", + }, + "messages": { + "noVarReqs": "Require statement not part of import statement.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "description": "Patterns of import paths to allow requiring from.", + "items": { + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "non-nullable-type-assertion-style": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce non-null assertions over explicit type casts", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/non-nullable-type-assertion-style", + }, + "fixable": "code", + "messages": { + "preferNonNullAssertion": "Use a ! assertion to more succinctly remove null and undefined from the type.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "object-curly-spacing": { + "create": [Function], + "defaultOptions": [ + "never", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing inside braces", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/object-curly-spacing", + }, + "fixable": "whitespace", + "messages": { + "requireSpaceAfter": "A space is required after '{{token}}'.", + "requireSpaceBefore": "A space is required before '{{token}}'.", + "unexpectedSpaceAfter": "There should be no space after '{{token}}'.", + "unexpectedSpaceBefore": "There should be no space before '{{token}}'.", + }, + "replacedBy": [ + "@stylistic/ts/object-curly-spacing", + ], + "schema": [ + { + "enum": [ + "always", + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "arraysInObjects": { + "type": "boolean", + }, + "objectsInObjects": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "only-throw-error": { + "create": [Function], + "defaultOptions": [ + { + "allowThrowingAny": true, + "allowThrowingUnknown": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow throwing non-\`Error\` values as exceptions", + "extendsBaseRule": "no-throw-literal", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/only-throw-error", + }, + "messages": { + "object": "Expected an error object to be thrown.", + "undef": "Do not throw undefined.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowThrowingAny": { + "type": "boolean", + }, + "allowThrowingUnknown": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "padding-line-between-statements": { + "create": [Function], + "defaultOptions": [], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow padding lines between statements", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/padding-line-between-statements", + }, + "fixable": "whitespace", + "hasSuggestions": false, + "messages": { + "expectedBlankLine": "Expected blank line before this statement.", + "unexpectedBlankLine": "Unexpected blank line before this statement.", + }, + "replacedBy": [ + "@stylistic/ts/padding-line-between-statements", + ], + "schema": { + "$defs": { + "paddingType": { + "enum": [ + "any", + "never", + "always", + ], + "type": "string", + }, + "statementType": { + "anyOf": [ + { + "enum": [ + "*", + "block-like", + "exports", + "require", + "directive", + "expression", + "iife", + "multiline-block-like", + "multiline-expression", + "multiline-const", + "multiline-let", + "multiline-var", + "singleline-const", + "singleline-let", + "singleline-var", + "block", + "empty", + "function", + "break", + "case", + "class", + "const", + "continue", + "debugger", + "default", + "do", + "export", + "for", + "if", + "import", + "let", + "return", + "switch", + "throw", + "try", + "var", + "while", + "with", + "interface", + "type", + ], + "type": "string", + }, + { + "additionalItems": false, + "items": { + "enum": [ + "*", + "block-like", + "exports", + "require", + "directive", + "expression", + "iife", + "multiline-block-like", + "multiline-expression", + "multiline-const", + "multiline-let", + "multiline-var", + "singleline-const", + "singleline-let", + "singleline-var", + "block", + "empty", + "function", + "break", + "case", + "class", + "const", + "continue", + "debugger", + "default", + "do", + "export", + "for", + "if", + "import", + "let", + "return", + "switch", + "throw", + "try", + "var", + "while", + "with", + "interface", + "type", + ], + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "additionalItems": false, + "items": { + "additionalProperties": false, + "properties": { + "blankLine": { + "$ref": "#/$defs/paddingType", + }, + "next": { + "$ref": "#/$defs/statementType", + }, + "prev": { + "$ref": "#/$defs/statementType", + }, + }, + "required": [ + "blankLine", + "prev", + "next", + ], + "type": "object", + }, + "type": "array", + }, + "type": "layout", + }, + }, + "parameter-properties": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "prefer": "class-property", + }, + ], + "meta": { + "docs": { + "description": "Require or disallow parameter properties in class constructors", + "url": "https://typescript-eslint.io/rules/parameter-properties", + }, + "messages": { + "preferClassProperty": "Property {{parameter}} should be declared as a class property.", + "preferParameterProperty": "Property {{parameter}} should be declared as a parameter property.", + }, + "schema": [ + { + "$defs": { + "modifier": { + "enum": [ + "readonly", + "private", + "protected", + "public", + "private readonly", + "protected readonly", + "public readonly", + ], + "type": "string", + }, + }, + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "$ref": "#/items/0/$defs/modifier", + }, + "type": "array", + }, + "prefer": { + "enum": [ + "class-property", + "parameter-property", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "prefer-as-const": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of \`as const\` over literal type", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/prefer-as-const", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "preferConstAssertion": "Expected a \`const\` instead of a literal type assertion.", + "variableConstAssertion": "Expected a \`const\` assertion instead of a literal type annotation.", + "variableSuggest": "You should use \`as const\` instead of type annotation.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-destructuring": { + "create": [Function], + "defaultOptions": [ + { + "AssignmentExpression": { + "array": true, + "object": true, + }, + "VariableDeclarator": { + "array": true, + "object": true, + }, + }, + {}, + ], + "meta": { + "docs": { + "description": "Require destructuring from arrays and/or objects", + "extendsBaseRule": true, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-destructuring", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "preferDestructuring": "Use {{type}} destructuring.", + }, + "schema": [ + { + "oneOf": [ + { + "additionalProperties": false, + "properties": { + "AssignmentExpression": { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + "VariableDeclarator": { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "array": { + "type": "boolean", + }, + "object": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + { + "properties": { + "enforceForDeclarationWithTypeAnnotation": { + "type": "boolean", + }, + "enforceForRenamedProperties": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-enum-initializers": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require each enum member value to be explicitly initialized", + "url": "https://typescript-eslint.io/rules/prefer-enum-initializers", + }, + "hasSuggestions": true, + "messages": { + "defineInitializer": "The value of the member '{{ name }}' should be explicitly defined.", + "defineInitializerSuggestion": "Can be fixed to {{ name }} = {{ suggested }}", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-find": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of Array.prototype.find() over Array.prototype.filter() followed by [0] when looking for a single result", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-find", + }, + "hasSuggestions": true, + "messages": { + "preferFind": "Prefer .find(...) instead of .filter(...)[0].", + "preferFindSuggestion": "Use .find(...) instead of .filter(...)[0].", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-for-of": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce the use of \`for-of\` loop over the standard \`for\` loop where possible", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-for-of", + }, + "messages": { + "preferForOf": "Expected a \`for-of\` loop instead of a \`for\` loop with this simple iteration.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-function-type": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using function types instead of interfaces with call signatures", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-function-type", + }, + "fixable": "code", + "messages": { + "functionTypeOverCallableType": "{{ literalOrInterface }} only has a call signature, you should use a function type instead.", + "unexpectedThisOnFunctionOnlyInterface": "\`this\` refers to the function type '{{ interfaceName }}', did you intend to use a generic \`this\` parameter like \`(this: Self, ...) => Self\` instead?", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-includes": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce \`includes\` method over \`indexOf\` method", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-includes", + }, + "fixable": "code", + "messages": { + "preferIncludes": "Use 'includes()' method instead.", + "preferStringIncludes": "Use \`String#includes()\` method with a string instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-literal-enum-member": { + "create": [Function], + "defaultOptions": [ + { + "allowBitwiseExpressions": false, + }, + ], + "meta": { + "docs": { + "description": "Require all enum members to be literal values", + "recommended": "strict", + "requiresTypeChecking": false, + "url": "https://typescript-eslint.io/rules/prefer-literal-enum-member", + }, + "messages": { + "notLiteral": "Explicit enum value must only be a literal value (string, number, boolean, etc).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowBitwiseExpressions": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-namespace-keyword": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Require using \`namespace\` keyword over \`module\` keyword to declare custom TypeScript modules", + "recommended": "stylistic", + "url": "https://typescript-eslint.io/rules/prefer-namespace-keyword", + }, + "fixable": "code", + "messages": { + "useNamespace": "Use 'namespace' instead of 'module' to declare custom TypeScript modules.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-nullish-coalescing": { + "create": [Function], + "defaultOptions": [ + { + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + "ignoreConditionalTests": false, + "ignoreMixedLogicalExpressions": false, + "ignorePrimitives": { + "bigint": false, + "boolean": false, + "number": false, + "string": false, + }, + "ignoreTernaryTests": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce using the nullish coalescing operator instead of logical assignments or chaining", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-nullish-coalescing", + }, + "hasSuggestions": true, + "messages": { + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + "preferNullishOverOr": "Prefer using nullish coalescing operator (\`??\`) instead of a logical or (\`||\`), as it is a safer operator.", + "preferNullishOverTernary": "Prefer using nullish coalescing operator (\`??\`) instead of a ternary expression, as it is simpler to read.", + "suggestNullish": "Fix to nullish coalescing operator (\`??\`).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "type": "boolean", + }, + "ignoreConditionalTests": { + "type": "boolean", + }, + "ignoreMixedLogicalExpressions": { + "type": "boolean", + }, + "ignorePrimitives": { + "oneOf": [ + { + "properties": { + "bigint": { + "type": "boolean", + }, + "boolean": { + "type": "boolean", + }, + "number": { + "type": "boolean", + }, + "string": { + "type": "boolean", + }, + }, + "type": "object", + }, + { + "enum": [ + true, + ], + "type": "boolean", + }, + ], + }, + "ignoreTernaryTests": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-optional-chain": { + "create": [Function], + "defaultOptions": [ + { + "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": false, + "checkAny": true, + "checkBigInt": true, + "checkBoolean": true, + "checkNumber": true, + "checkString": true, + "checkUnknown": true, + "requireNullish": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce using concise optional chain expressions instead of chained logical ands, negated logical ors, or empty objects", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-optional-chain", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "optionalChainSuggest": "Change to an optional chain.", + "preferOptionalChain": "Prefer using an optional chain expression instead, as it's more concise and easier to read.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowPotentiallyUnsafeFixesThatModifyTheReturnTypeIKnowWhatImDoing": { + "description": "Allow autofixers that will change the return type of the expression. This option is considered unsafe as it may break the build.", + "type": "boolean", + }, + "checkAny": { + "description": "Check operands that are typed as \`any\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkBigInt": { + "description": "Check operands that are typed as \`bigint\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkBoolean": { + "description": "Check operands that are typed as \`boolean\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkNumber": { + "description": "Check operands that are typed as \`number\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkString": { + "description": "Check operands that are typed as \`string\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "checkUnknown": { + "description": "Check operands that are typed as \`unknown\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + "requireNullish": { + "description": "Skip operands that are not typed with \`null\` and/or \`undefined\` when inspecting "loose boolean" operands.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-promise-reject-errors": { + "create": [Function], + "defaultOptions": [ + { + "allowEmptyReject": false, + }, + ], + "meta": { + "docs": { + "description": "Require using Error objects as Promise rejection reasons", + "extendsBaseRule": true, + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-promise-reject-errors", + }, + "messages": { + "rejectAnError": "Expected the Promise rejection reason to be an Error.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowEmptyReject": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-readonly": { + "create": [Function], + "defaultOptions": [ + { + "onlyInlineLambdas": false, + }, + ], + "meta": { + "docs": { + "description": "Require private members to be marked as \`readonly\` if they're never modified outside of the constructor", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-readonly", + }, + "fixable": "code", + "messages": { + "preferReadonly": "Member '{{name}}' is never reassigned; mark it as \`readonly\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "onlyInlineLambdas": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-readonly-parameter-types": { + "create": [Function], + "defaultOptions": [ + { + "allow": [], + "checkParameterProperties": true, + "ignoreInferredTypes": false, + "treatMethodsAsReadonly": false, + }, + ], + "meta": { + "docs": { + "description": "Require function parameters to be typed as \`readonly\` to prevent accidental mutation of inputs", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-readonly-parameter-types", + }, + "messages": { + "shouldBeReadonly": "Parameter should be a read only type.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allow": { + "items": { + "oneOf": [ + { + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "file", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + "path": { + "type": "string", + }, + }, + "required": [ + "from", + "name", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "lib", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + }, + "required": [ + "from", + "name", + ], + "type": "object", + }, + { + "additionalProperties": false, + "properties": { + "from": { + "enum": [ + "package", + ], + "type": "string", + }, + "name": { + "oneOf": [ + { + "type": "string", + }, + { + "items": { + "type": "string", + }, + "minItems": 1, + "type": "array", + "uniqueItems": true, + }, + ], + }, + "package": { + "type": "string", + }, + }, + "required": [ + "from", + "name", + "package", + ], + "type": "object", + }, + ], + }, + "type": "array", + }, + "checkParameterProperties": { + "type": "boolean", + }, + "ignoreInferredTypes": { + "type": "boolean", + }, + "treatMethodsAsReadonly": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-reduce-type-parameter": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using type parameter when calling \`Array#reduce\` instead of casting", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-reduce-type-parameter", + }, + "fixable": "code", + "messages": { + "preferTypeParameter": "Unnecessary cast: Array#reduce accepts a type parameter for the default value.", + }, + "schema": [], + "type": "problem", + }, + }, + "prefer-regexp-exec": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce \`RegExp#exec\` over \`String#match\` if no global flag is provided", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-regexp-exec", + }, + "fixable": "code", + "messages": { + "regExpExecOverStringMatch": "Use the \`RegExp#exec()\` method instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-return-this-type": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce that \`this\` is used when only \`this\` type is returned", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-return-this-type", + }, + "fixable": "code", + "messages": { + "useThisType": "Use \`this\` type instead.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "prefer-string-starts-ends-with": { + "create": [Function], + "defaultOptions": [ + { + "allowSingleElementEquality": "never", + }, + ], + "meta": { + "docs": { + "description": "Enforce using \`String#startsWith\` and \`String#endsWith\` over other equivalent methods of checking substrings", + "recommended": "stylistic", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/prefer-string-starts-ends-with", + }, + "fixable": "code", + "messages": { + "preferEndsWith": "Use the 'String#endsWith' method instead.", + "preferStartsWith": "Use 'String#startsWith' method instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowSingleElementEquality": { + "description": "Whether to allow equality checks against the first or last element of a string.", + "enum": [ + "always", + "never", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "prefer-ts-expect-error": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce using \`@ts-expect-error\` over \`@ts-ignore\`", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/prefer-ts-expect-error", + }, + "fixable": "code", + "messages": { + "preferExpectErrorComment": "Use "@ts-expect-error" to ensure an error is actually being suppressed.", + }, + "schema": [], + "type": "problem", + }, + }, + "promise-function-async": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowedPromiseNames": [], + "checkArrowFunctions": true, + "checkFunctionDeclarations": true, + "checkFunctionExpressions": true, + "checkMethodDeclarations": true, + }, + ], + "meta": { + "docs": { + "description": "Require any function or method that returns a Promise to be marked async", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/promise-function-async", + }, + "fixable": "code", + "messages": { + "missingAsync": "Functions that return promises must be async.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to consider \`any\` and \`unknown\` to be Promises.", + "type": "boolean", + }, + "allowedPromiseNames": { + "description": "Any extra names of classes or interfaces to be considered Promises.", + "items": { + "type": "string", + }, + "type": "array", + }, + "checkArrowFunctions": { + "type": "boolean", + }, + "checkFunctionDeclarations": { + "type": "boolean", + }, + "checkFunctionExpressions": { + "type": "boolean", + }, + "checkMethodDeclarations": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "quotes": { + "create": [Function], + "defaultOptions": [ + "double", + { + "allowTemplateLiterals": false, + "avoidEscape": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce the consistent use of either backticks, double, or single quotes", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/quotes", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "wrongQuotes": "Strings must use {{description}}.", + }, + "replacedBy": [ + "@stylistic/ts/quotes", + ], + "schema": [ + { + "enum": [ + "single", + "double", + "backtick", + ], + }, + { + "anyOf": [ + { + "enum": [ + "avoid-escape", + ], + }, + { + "additionalProperties": false, + "properties": { + "allowTemplateLiterals": { + "type": "boolean", + }, + "avoidEscape": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "require-array-sort-compare": { + "create": [Function], + "defaultOptions": [ + { + "ignoreStringArrays": true, + }, + ], + "meta": { + "docs": { + "description": "Require \`Array#sort\` and \`Array#toSorted\` calls to always provide a \`compareFunction\`", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/require-array-sort-compare", + }, + "messages": { + "requireCompare": "Require 'compare' argument.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreStringArrays": { + "description": "Whether to ignore arrays in which all elements are strings.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "require-await": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Disallow async functions which have no \`await\` expression", + "extendsBaseRule": true, + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/require-await", + }, + "messages": { + "missingAwait": "{{name}} has no 'await' expression.", + }, + "schema": [], + "type": "suggestion", + }, + }, + "restrict-plus-operands": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowBoolean": true, + "allowNullish": true, + "allowNumberAndString": true, + "allowRegExp": true, + "skipCompoundAssignments": false, + }, + ], + "meta": { + "docs": { + "description": "Require both operands of addition to be the same type and be \`bigint\`, \`number\`, or \`string\`", + "recommended": { + "recommended": true, + "strict": [ + { + "allowAny": false, + "allowBoolean": false, + "allowNullish": false, + "allowNumberAndString": false, + "allowRegExp": false, + }, + ], + }, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/restrict-plus-operands", + }, + "messages": { + "bigintAndNumber": "Numeric '+' operations must either be both bigints or both numbers. Got \`{{left}}\` + \`{{right}}\`.", + "invalid": "Invalid operand for a '+' operation. Operands must each be a number or {{stringLike}}. Got \`{{type}}\`.", + "mismatched": "Operands of '+' operations must be a number or {{stringLike}}. Got \`{{left}}\` + \`{{right}}\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to allow \`any\` typed values.", + "type": "boolean", + }, + "allowBoolean": { + "description": "Whether to allow \`boolean\` typed values.", + "type": "boolean", + }, + "allowNullish": { + "description": "Whether to allow potentially \`null\` or \`undefined\` typed values.", + "type": "boolean", + }, + "allowNumberAndString": { + "description": "Whether to allow \`bigint\`/\`number\` typed values and \`string\` typed values to be added together.", + "type": "boolean", + }, + "allowRegExp": { + "description": "Whether to allow \`regexp\` typed values.", + "type": "boolean", + }, + "skipCompoundAssignments": { + "description": "Whether to skip compound assignments such as \`+=\`.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "restrict-template-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": true, + "allowBoolean": true, + "allowNullish": true, + "allowNumber": true, + "allowRegExp": true, + }, + ], + "meta": { + "docs": { + "description": "Enforce template literal expressions to be of \`string\` type", + "recommended": { + "recommended": true, + "strict": [ + { + "allowAny": false, + "allowBoolean": false, + "allowNever": false, + "allowNullish": false, + "allowNumber": false, + "allowRegExp": false, + }, + ], + }, + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/restrict-template-expressions", + }, + "messages": { + "invalidType": "Invalid type "{{type}}" of template literal expression.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "description": "Whether to allow \`any\` typed values in template expressions.", + "type": "boolean", + }, + "allowArray": { + "description": "Whether to allow \`array\` typed values in template expressions.", + "type": "boolean", + }, + "allowBoolean": { + "description": "Whether to allow \`boolean\` typed values in template expressions.", + "type": "boolean", + }, + "allowNever": { + "description": "Whether to allow \`never\` typed values in template expressions.", + "type": "boolean", + }, + "allowNullish": { + "description": "Whether to allow \`nullish\` typed values in template expressions.", + "type": "boolean", + }, + "allowNumber": { + "description": "Whether to allow \`number\` typed values in template expressions.", + "type": "boolean", + }, + "allowRegExp": { + "description": "Whether to allow \`regexp\` typed values in template expressions.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "return-await": { + "create": [Function], + "defaultOptions": [ + "in-try-catch", + ], + "meta": { + "docs": { + "description": "Enforce consistent returning of awaited values", + "extendsBaseRule": "no-return-await", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/return-await", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "disallowedPromiseAwait": "Returning an awaited promise is not allowed in this context.", + "nonPromiseAwait": "Returning an awaited value that is not a promise is not allowed.", + "requiredPromiseAwait": "Returning an awaited promise is required in this context.", + }, + "schema": [ + { + "enum": [ + "in-try-catch", + "always", + "never", + ], + "type": "string", + }, + ], + "type": "problem", + }, + }, + "semi": { + "create": [Function], + "defaultOptions": [ + "always", + { + "beforeStatementContinuationChars": "any", + "omitLastInOneLineBlock": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require or disallow semicolons instead of ASI", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/semi", + }, + "fixable": "code", + "hasSuggestions": undefined, + "messages": { + "extraSemi": "Extra semicolon.", + "missingSemi": "Missing semicolon.", + }, + "replacedBy": [ + "@stylistic/ts/semi", + ], + "schema": { + "anyOf": [ + { + "items": [ + { + "enum": [ + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "beforeStatementContinuationChars": { + "enum": [ + "always", + "any", + "never", + ], + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + { + "items": [ + { + "enum": [ + "always", + ], + }, + { + "additionalProperties": false, + "properties": { + "omitLastInOneLineBlock": { + "type": "boolean", + }, + "omitLastInOneLineClassBody": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "maxItems": 2, + "minItems": 0, + "type": "array", + }, + ], + }, + "type": "layout", + }, + }, + "sort-type-constituents": { + "create": [Function], + "defaultOptions": [ + { + "checkIntersections": true, + "checkUnions": true, + "groupOrder": [ + "named", + "keyword", + "operator", + "literal", + "function", + "import", + "conditional", + "object", + "tuple", + "intersection", + "union", + "nullish", + ], + }, + ], + "meta": { + "docs": { + "description": "Enforce constituents of a type union/intersection to be sorted alphabetically", + "url": "https://typescript-eslint.io/rules/sort-type-constituents", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "notSorted": "{{type}} type constituents must be sorted.", + "notSortedNamed": "{{type}} type {{name}} constituents must be sorted.", + "suggestFix": "Sort constituents of type (removes all comments).", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "checkIntersections": { + "description": "Whether to check intersection types.", + "type": "boolean", + }, + "checkUnions": { + "description": "Whether to check union types.", + "type": "boolean", + }, + "groupOrder": { + "description": "Ordering of the groups.", + "items": { + "enum": [ + "conditional", + "function", + "import", + "intersection", + "keyword", + "nullish", + "literal", + "named", + "object", + "operator", + "tuple", + "union", + ], + "type": "string", + }, + "type": "array", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "space-before-blocks": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before blocks", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-before-blocks", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "missingSpace": "Missing space before opening brace.", + "unexpectedSpace": "Unexpected space before opening brace.", + }, + "replacedBy": [ + "@stylistic/ts/space-before-blocks", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "always", + "never", + ], + }, + { + "additionalProperties": false, + "properties": { + "classes": { + "enum": [ + "always", + "never", + "off", + ], + }, + "functions": { + "enum": [ + "always", + "never", + "off", + ], + }, + "keywords": { + "enum": [ + "always", + "never", + "off", + ], + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "space-before-function-paren": { + "create": [Function], + "defaultOptions": [ + "always", + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Enforce consistent spacing before function parenthesis", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-before-function-paren", + }, + "fixable": "whitespace", + "messages": { + "missing": "Missing space before function parentheses.", + "unexpected": "Unexpected space before function parentheses.", + }, + "replacedBy": [ + "@stylistic/ts/space-before-function-paren", + ], + "schema": [ + { + "oneOf": [ + { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + { + "additionalProperties": false, + "properties": { + "anonymous": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + "asyncArrow": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + "named": { + "enum": [ + "always", + "never", + "ignore", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + }, + ], + "type": "layout", + }, + }, + "space-infix-ops": { + "create": [Function], + "defaultOptions": [ + { + "int32Hint": false, + }, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require spacing around infix operators", + "extendsBaseRule": true, + "url": "https://typescript-eslint.io/rules/space-infix-ops", + }, + "fixable": "whitespace", + "hasSuggestions": undefined, + "messages": { + "missingSpace": "Operator '{{operator}}' must be spaced.", + }, + "replacedBy": [ + "@stylistic/ts/space-infix-ops", + ], + "schema": [ + { + "additionalProperties": false, + "properties": { + "int32Hint": { + "default": false, + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "strict-boolean-expressions": { + "create": [Function], + "defaultOptions": [ + { + "allowAny": false, + "allowNullableBoolean": false, + "allowNullableEnum": false, + "allowNullableNumber": false, + "allowNullableObject": true, + "allowNullableString": false, + "allowNumber": true, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": false, + "allowString": true, + }, + ], + "meta": { + "docs": { + "description": "Disallow certain types in boolean expressions", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/strict-boolean-expressions", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "conditionErrorAny": "Unexpected any value in conditional. An explicit comparison or type cast is required.", + "conditionErrorNullableBoolean": "Unexpected nullable boolean value in conditional. Please handle the nullish case explicitly.", + "conditionErrorNullableEnum": "Unexpected nullable enum value in conditional. Please handle the nullish/zero/NaN cases explicitly.", + "conditionErrorNullableNumber": "Unexpected nullable number value in conditional. Please handle the nullish/zero/NaN cases explicitly.", + "conditionErrorNullableObject": "Unexpected nullable object value in conditional. An explicit null check is required.", + "conditionErrorNullableString": "Unexpected nullable string value in conditional. Please handle the nullish/empty cases explicitly.", + "conditionErrorNullish": "Unexpected nullish value in conditional. The condition is always false.", + "conditionErrorNumber": "Unexpected number value in conditional. An explicit zero/NaN check is required.", + "conditionErrorObject": "Unexpected object value in conditional. The condition is always true.", + "conditionErrorOther": "Unexpected value in conditional. A boolean expression is required.", + "conditionErrorString": "Unexpected string value in conditional. An explicit empty string check is required.", + "conditionFixCastBoolean": "Explicitly cast value to a boolean (\`Boolean(value)\`)", + "conditionFixCompareEmptyString": "Change condition to check for empty string (\`value !== ""\`)", + "conditionFixCompareFalse": "Change condition to check if false (\`value === false\`)", + "conditionFixCompareNaN": "Change condition to check for NaN (\`!Number.isNaN(value)\`)", + "conditionFixCompareNullish": "Change condition to check for null/undefined (\`value != null\`)", + "conditionFixCompareStringLength": "Change condition to check string's length (\`value.length !== 0\`)", + "conditionFixCompareTrue": "Change condition to check if true (\`value === true\`)", + "conditionFixCompareZero": "Change condition to check for 0 (\`value !== 0\`)", + "conditionFixDefaultEmptyString": "Explicitly treat nullish value the same as an empty string (\`value ?? ""\`)", + "conditionFixDefaultFalse": "Explicitly treat nullish value the same as false (\`value ?? false\`)", + "conditionFixDefaultZero": "Explicitly treat nullish value the same as 0 (\`value ?? 0\`)", + "noStrictNullCheck": "This rule requires the \`strictNullChecks\` compiler option to be turned on to function correctly.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowAny": { + "type": "boolean", + }, + "allowNullableBoolean": { + "type": "boolean", + }, + "allowNullableEnum": { + "type": "boolean", + }, + "allowNullableNumber": { + "type": "boolean", + }, + "allowNullableObject": { + "type": "boolean", + }, + "allowNullableString": { + "type": "boolean", + }, + "allowNumber": { + "type": "boolean", + }, + "allowRuleToRunWithoutStrictNullChecksIKnowWhatIAmDoing": { + "type": "boolean", + }, + "allowString": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "switch-exhaustiveness-check": { + "create": [Function], + "defaultOptions": [ + { + "allowDefaultCaseForExhaustiveSwitch": true, + "requireDefaultForNonUnion": false, + }, + ], + "meta": { + "docs": { + "description": "Require switch-case statements to be exhaustive", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/switch-exhaustiveness-check", + }, + "hasSuggestions": true, + "messages": { + "addMissingCases": "Add branches for missing cases.", + "dangerousDefaultCase": "The switch statement is exhaustive, so the default case is unnecessary.", + "switchIsNotExhaustive": "Switch is not exhaustive. Cases not matched: {{missingBranches}}", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "allowDefaultCaseForExhaustiveSwitch": { + "description": "If 'true', allow 'default' cases on switch statements with exhaustive cases.", + "type": "boolean", + }, + "requireDefaultForNonUnion": { + "description": "If 'true', require a 'default' clause for switches on non-union types.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "triple-slash-reference": { + "create": [Function], + "defaultOptions": [ + { + "lib": "always", + "path": "never", + "types": "prefer-import", + }, + ], + "meta": { + "docs": { + "description": "Disallow certain triple slash directives in favor of ES6-style import declarations", + "recommended": "recommended", + "url": "https://typescript-eslint.io/rules/triple-slash-reference", + }, + "messages": { + "tripleSlashReference": "Do not use a triple slash reference for {{module}}, use \`import\` style instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "lib": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + "path": { + "enum": [ + "always", + "never", + ], + "type": "string", + }, + "types": { + "enum": [ + "always", + "never", + "prefer-import", + ], + "type": "string", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "type-annotation-spacing": { + "create": [Function], + "defaultOptions": [ + {}, + ], + "meta": { + "deprecated": true, + "docs": { + "description": "Require consistent spacing around type annotations", + "url": "https://typescript-eslint.io/rules/type-annotation-spacing", + }, + "fixable": "whitespace", + "messages": { + "expectedSpaceAfter": "Expected a space after the '{{type}}'.", + "expectedSpaceBefore": "Expected a space before the '{{type}}'.", + "unexpectedSpaceAfter": "Unexpected space after the '{{type}}'.", + "unexpectedSpaceBefore": "Unexpected space before the '{{type}}'.", + "unexpectedSpaceBetween": "Unexpected space between the '{{previousToken}}' and the '{{type}}'.", + }, + "replacedBy": [ + "@stylistic/ts/type-annotation-spacing", + ], + "schema": [ + { + "$defs": { + "spacingConfig": { + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + }, + "type": "object", + }, + }, + "additionalProperties": false, + "properties": { + "after": { + "type": "boolean", + }, + "before": { + "type": "boolean", + }, + "overrides": { + "additionalProperties": false, + "properties": { + "arrow": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "colon": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "parameter": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "property": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "returnType": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + "variable": { + "$ref": "#/items/0/$defs/spacingConfig", + }, + }, + "type": "object", + }, + }, + "type": "object", + }, + ], + "type": "layout", + }, + }, + "typedef": { + "create": [Function], + "defaultOptions": [ + { + "arrayDestructuring": false, + "arrowParameter": false, + "memberVariableDeclaration": false, + "objectDestructuring": false, + "parameter": false, + "propertyDeclaration": false, + "variableDeclaration": false, + "variableDeclarationIgnoreFunction": false, + }, + ], + "meta": { + "docs": { + "description": "Require type annotations in certain places", + "url": "https://typescript-eslint.io/rules/typedef", + }, + "messages": { + "expectedTypedef": "Expected a type annotation.", + "expectedTypedefNamed": "Expected {{name}} to have a type annotation.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "arrayDestructuring": { + "type": "boolean", + }, + "arrowParameter": { + "type": "boolean", + }, + "memberVariableDeclaration": { + "type": "boolean", + }, + "objectDestructuring": { + "type": "boolean", + }, + "parameter": { + "type": "boolean", + }, + "propertyDeclaration": { + "type": "boolean", + }, + "variableDeclaration": { + "type": "boolean", + }, + "variableDeclarationIgnoreFunction": { + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "unbound-method": { + "create": [Function], + "defaultOptions": [ + { + "ignoreStatic": false, + }, + ], + "meta": { + "docs": { + "description": "Enforce unbound methods are called with their expected scope", + "recommended": "recommended", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/unbound-method", + }, + "messages": { + "unbound": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`.", + "unboundWithoutThisAnnotation": "Avoid referencing unbound methods which may cause unintentional scoping of \`this\`. +If your function does not access \`this\`, you can annotate it with \`this: void\`, or consider using an arrow function instead.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreStatic": { + "description": "Whether to skip checking whether \`static\` methods are correctly bound.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "problem", + }, + }, + "unified-signatures": { + "create": [Function], + "defaultOptions": [ + { + "ignoreDifferentlyNamedParameters": false, + }, + ], + "meta": { + "docs": { + "description": "Disallow two overloads that could be unified into one with a union or an optional/rest parameter", + "recommended": "strict", + "url": "https://typescript-eslint.io/rules/unified-signatures", + }, + "messages": { + "omittingRestParameter": "{{failureStringStart}} with a rest parameter.", + "omittingSingleParameter": "{{failureStringStart}} with an optional parameter.", + "singleParameterDifference": "{{failureStringStart}} taking \`{{type1}} | {{type2}}\`.", + }, + "schema": [ + { + "additionalProperties": false, + "properties": { + "ignoreDifferentlyNamedParameters": { + "description": "Whether two parameters with different names at the same index should be considered different even if their types are the same.", + "type": "boolean", + }, + }, + "type": "object", + }, + ], + "type": "suggestion", + }, + }, + "use-unknown-in-catch-callback-variable": { + "create": [Function], + "defaultOptions": [], + "meta": { + "docs": { + "description": "Enforce typing arguments in \`.catch()\` callbacks as \`unknown\`", + "recommended": "strict", + "requiresTypeChecking": true, + "url": "https://typescript-eslint.io/rules/use-unknown-in-catch-callback-variable", + }, + "fixable": "code", + "hasSuggestions": true, + "messages": { + "addUnknownRestTypeAnnotationSuggestion": "Add an explicit \`: [unknown]\` type annotation to the catch rest variable.", + "addUnknownTypeAnnotationSuggestion": "Add an explicit \`: unknown\` type annotation to the catch variable.", + "useUnknown": "Prefer the safe \`: unknown\` for a catch callback variable.", + "useUnknownArrayDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may not be iterable.", + "useUnknownObjectDestructuringPattern": "Prefer the safe \`: unknown\` for a catch callback variable. The thrown error may be nullable, or may not have the expected shape.", + "useUnknownSpreadArgs": "Prefer the safe \`: unknown\` for a catch callback variable. The argument list may contain a handler that does not use \`unknown\` for the catch callback variable.", + "wrongRestTypeAnnotationSuggestion": "Change existing type annotation to \`: [unknown]\`.", + "wrongTypeAnnotationSuggestion": "Change existing type annotation to \`: unknown\`.", + }, + "schema": [], + "type": "suggestion", + }, + }, + }, + }, + }, + }, + { + "files": [ + "**/*.ts", + "**/*.tsx", + "**/*.mts", + "**/*.cts", + ], + "name": "typescript-eslint/eslint-recommended", + "rules": { + "constructor-super": "off", + "getter-return": "off", + "no-const-assign": "off", + "no-dupe-args": "off", + "no-dupe-class-members": "off", + "no-dupe-keys": "off", + "no-func-assign": "off", + "no-import-assign": "off", + "no-new-symbol": "off", + "no-obj-calls": "off", + "no-redeclare": "off", + "no-setter-return": "off", + "no-this-before-super": "off", + "no-undef": "off", + "no-unreachable": "off", + "no-unsafe-negation": "off", + "no-var": "error", + "prefer-const": "error", + "prefer-rest-params": "error", + "prefer-spread": "error", + }, + }, + { + "name": "typescript-eslint/stylistic-type-checked", + "rules": { + "@typescript-eslint/adjacent-overload-signatures": "error", + "@typescript-eslint/array-type": "error", + "@typescript-eslint/ban-tslint-comment": "error", + "@typescript-eslint/class-literal-property-style": "error", + "@typescript-eslint/consistent-generic-constructors": "error", + "@typescript-eslint/consistent-indexed-object-style": "error", + "@typescript-eslint/consistent-type-assertions": "error", + "@typescript-eslint/consistent-type-definitions": "error", + "@typescript-eslint/dot-notation": "error", + "@typescript-eslint/no-confusing-non-null-assertion": "error", + "@typescript-eslint/no-empty-function": "error", + "@typescript-eslint/no-empty-interface": "error", + "@typescript-eslint/no-inferrable-types": "error", + "@typescript-eslint/non-nullable-type-assertion-style": "error", + "@typescript-eslint/prefer-for-of": "error", + "@typescript-eslint/prefer-function-type": "error", + "@typescript-eslint/prefer-namespace-keyword": "error", + "@typescript-eslint/prefer-nullish-coalescing": "error", + "@typescript-eslint/prefer-optional-chain": "error", + "@typescript-eslint/prefer-string-starts-ends-with": "error", + "dot-notation": "off", + "no-empty-function": "off", + }, + }, + { + "languageOptions": { + "parserOptions": { + "project": "/", + "tsconfigRootDir": "/", + }, + }, + "name": "jimmy.codes/typescript", + "rules": { + "@typescript-eslint/consistent-type-exports": [ + "error", + { + "fixMixedExportsWithInlineTypeSpecifier": true, + }, + ], + "@typescript-eslint/consistent-type-imports": [ + "error", + { + "fixStyle": "inline-type-imports", + }, + ], + "@typescript-eslint/no-misused-promises": [ + "error", + { + "checksVoidReturn": { + "attributes": false, + }, + }, + ], + }, + }, + { + "files": [ + "**/*.?([cm])js", + "**/*.?([cm])jsx", + ], + "languageOptions": { + "parserOptions": { + "program": null, + "project": false, + }, + }, + "name": "typescript-eslint/disable-type-checked", + "rules": { + "@typescript-eslint/await-thenable": "off", + "@typescript-eslint/consistent-return": "off", + "@typescript-eslint/consistent-type-exports": "off", + "@typescript-eslint/dot-notation": "off", + "@typescript-eslint/naming-convention": "off", + "@typescript-eslint/no-array-delete": "off", + "@typescript-eslint/no-base-to-string": "off", + "@typescript-eslint/no-confusing-void-expression": "off", + "@typescript-eslint/no-duplicate-type-constituents": "off", + "@typescript-eslint/no-floating-promises": "off", + "@typescript-eslint/no-for-in-array": "off", + "@typescript-eslint/no-implied-eval": "off", + "@typescript-eslint/no-meaningless-void-operator": "off", + "@typescript-eslint/no-misused-promises": "off", + "@typescript-eslint/no-mixed-enums": "off", + "@typescript-eslint/no-redundant-type-constituents": "off", + "@typescript-eslint/no-throw-literal": "off", + "@typescript-eslint/no-unnecessary-boolean-literal-compare": "off", + "@typescript-eslint/no-unnecessary-condition": "off", + "@typescript-eslint/no-unnecessary-qualifier": "off", + "@typescript-eslint/no-unnecessary-type-arguments": "off", + "@typescript-eslint/no-unnecessary-type-assertion": "off", + "@typescript-eslint/no-unsafe-argument": "off", + "@typescript-eslint/no-unsafe-assignment": "off", + "@typescript-eslint/no-unsafe-call": "off", + "@typescript-eslint/no-unsafe-enum-comparison": "off", + "@typescript-eslint/no-unsafe-member-access": "off", + "@typescript-eslint/no-unsafe-return": "off", + "@typescript-eslint/no-unsafe-unary-minus": "off", + "@typescript-eslint/no-useless-template-literals": "off", + "@typescript-eslint/non-nullable-type-assertion-style": "off", + "@typescript-eslint/only-throw-error": "off", + "@typescript-eslint/prefer-destructuring": "off", + "@typescript-eslint/prefer-find": "off", + "@typescript-eslint/prefer-includes": "off", + "@typescript-eslint/prefer-nullish-coalescing": "off", + "@typescript-eslint/prefer-optional-chain": "off", + "@typescript-eslint/prefer-promise-reject-errors": "off", + "@typescript-eslint/prefer-readonly": "off", + "@typescript-eslint/prefer-readonly-parameter-types": "off", + "@typescript-eslint/prefer-reduce-type-parameter": "off", + "@typescript-eslint/prefer-regexp-exec": "off", + "@typescript-eslint/prefer-return-this-type": "off", + "@typescript-eslint/prefer-string-starts-ends-with": "off", + "@typescript-eslint/promise-function-async": "off", + "@typescript-eslint/require-array-sort-compare": "off", + "@typescript-eslint/require-await": "off", + "@typescript-eslint/restrict-plus-operands": "off", + "@typescript-eslint/restrict-template-expressions": "off", + "@typescript-eslint/return-await": "off", + "@typescript-eslint/strict-boolean-expressions": "off", + "@typescript-eslint/switch-exhaustiveness-check": "off", + "@typescript-eslint/unbound-method": "off", + "@typescript-eslint/use-unknown-in-catch-callback-variable": "off", + }, + }, +] +`; diff --git a/src/configs/typescript.spec.ts b/src/configs/typescript.spec.ts new file mode 100644 index 0000000..c06fa68 --- /dev/null +++ b/src/configs/typescript.spec.ts @@ -0,0 +1,9 @@ +import typescriptConfig from "./typescript"; + +describe("typescriptConfig", () => { + it("should create config", () => { + vi.spyOn(process, "cwd").mockReturnValue("/"); + + expect(typescriptConfig({ project: "/" })).toMatchSnapshot(); + }); +}); diff --git a/src/configs/typescript.ts b/src/configs/typescript.ts index 8cc9862..c34eb13 100644 --- a/src/configs/typescript.ts +++ b/src/configs/typescript.ts @@ -5,17 +5,16 @@ import { type TypescriptOptions } from "../types"; const typescriptConfig = (options: TypescriptOptions) => { return config( + ...configs.strictTypeChecked, { - //@ts-expect-error name should be allowed or provided name: "jimmy.codes/typescript", - extends: [ - ...configs.strictTypeChecked.map((config) => { - return { name: "jimmy.codes/typescript", ...config }; - }), - ...configs.stylisticTypeChecked.map((config) => { - return { name: "jimmy.codes/typescript", ...config }; - }), - ], + extends: [...configs.strictTypeChecked, ...configs.stylisticTypeChecked], + languageOptions: { + parserOptions: { + project: options.project, + tsconfigRootDir: process.cwd(), + }, + }, rules: { "@typescript-eslint/consistent-type-imports": [ "error", @@ -32,16 +31,6 @@ const typescriptConfig = (options: TypescriptOptions) => { }, }, { - name: "jimmy.codes/typescript", - languageOptions: { - parserOptions: { - project: options.project, - tsconfigRootDir: process.cwd(), - }, - }, - }, - { - name: "jimmy.codes/typescript", files: [GLOB_JS, GLOB_JSX], ...configs.disableTypeChecked, }, diff --git a/src/factory.spec.ts b/src/factory.spec.ts index 79fdf6b..b95cfea 100644 --- a/src/factory.spec.ts +++ b/src/factory.spec.ts @@ -6,9 +6,12 @@ describe("jimmyDotCodes", () => { }); it("should create configuration w/ typescript", () => { - vi.spyOn(process, "cwd").mockReturnValue("/"); - - expect(jimmyDotCodes({ typescript: true })).toMatchSnapshot(); + expect(jimmyDotCodes({ typescript: true })).toStrictEqual( + expect.arrayContaining([ + expect.objectContaining({ name: "jimmy.codes/typescript" }), + expect.objectContaining({ name: "jimmy.codes/imports/typescript" }), + ]), + ); }); it("should create configuration w/ react", () => { diff --git a/vitest.config.ts b/vitest.config.ts index 5df2aca..8a342e3 100644 --- a/vitest.config.ts +++ b/vitest.config.ts @@ -3,6 +3,9 @@ import { configDefaults, defineConfig } from "vitest/config"; export default defineConfig({ test: { globals: true, + mockReset: true, + clearMocks: true, + restoreMocks: true, coverage: { exclude: [...(configDefaults.coverage.exclude ?? []), "fixtures/**"], },