@askviraj/linter 1.1.4 → 1.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/node_modules/@astrojs/compiler-binding/package.json +10 -10
- package/node_modules/@astrojs/compiler-binding-darwin-arm64/README.md +3 -0
- package/node_modules/@astrojs/compiler-binding-darwin-arm64/astro.darwin-arm64.node +0 -0
- package/node_modules/@astrojs/compiler-binding-darwin-arm64/package.json +37 -0
- package/node_modules/@astrojs/compiler-binding-darwin-x64/README.md +3 -0
- package/node_modules/@astrojs/compiler-binding-darwin-x64/astro.darwin-x64.node +0 -0
- package/node_modules/@astrojs/compiler-binding-darwin-x64/package.json +37 -0
- package/node_modules/@astrojs/compiler-binding-linux-arm64-gnu/README.md +3 -0
- package/node_modules/@astrojs/compiler-binding-linux-arm64-gnu/astro.linux-arm64-gnu.node +0 -0
- package/node_modules/@astrojs/compiler-binding-linux-arm64-gnu/package.json +40 -0
- package/node_modules/@astrojs/compiler-binding-linux-arm64-musl/README.md +3 -0
- package/node_modules/@astrojs/compiler-binding-linux-arm64-musl/astro.linux-arm64-musl.node +0 -0
- package/node_modules/@astrojs/compiler-binding-linux-arm64-musl/package.json +40 -0
- package/node_modules/@astrojs/compiler-binding-linux-x64-gnu/astro.linux-x64-gnu.node +0 -0
- package/node_modules/@astrojs/compiler-binding-linux-x64-gnu/package.json +1 -1
- package/node_modules/@astrojs/compiler-binding-linux-x64-musl/README.md +3 -0
- package/node_modules/@astrojs/compiler-binding-linux-x64-musl/astro.linux-x64-musl.node +0 -0
- package/node_modules/@astrojs/compiler-binding-linux-x64-musl/package.json +40 -0
- package/node_modules/@astrojs/compiler-binding-win32-arm64-msvc/README.md +3 -0
- package/node_modules/@astrojs/compiler-binding-win32-arm64-msvc/astro.win32-arm64-msvc.node +0 -0
- package/node_modules/@astrojs/compiler-binding-win32-arm64-msvc/package.json +37 -0
- package/node_modules/@astrojs/compiler-binding-win32-x64-msvc/README.md +3 -0
- package/node_modules/@astrojs/compiler-binding-win32-x64-msvc/astro.win32-x64-msvc.node +0 -0
- package/node_modules/@astrojs/compiler-binding-win32-x64-msvc/package.json +37 -0
- package/node_modules/@astrojs/compiler-rs/package.json +2 -2
- package/node_modules/@html-eslint/core/dist/index.js +2 -0
- package/node_modules/@html-eslint/core/dist/index.js.map +1 -1
- package/node_modules/@html-eslint/core/dist/index.mjs +2 -0
- package/node_modules/@html-eslint/core/dist/index.mjs.map +1 -1
- package/node_modules/@html-eslint/core/package.json +3 -3
- package/node_modules/@html-eslint/eslint-plugin/lib/rules/no-duplicate-attrs.js +140 -16
- package/node_modules/@html-eslint/eslint-plugin/lib/rules/no-duplicate-id.js +24 -5
- package/node_modules/@html-eslint/eslint-plugin/lib/rules/no-duplicate-in-head.js +17 -5
- package/node_modules/@html-eslint/eslint-plugin/lib/rules/utils/branch-segments.js +147 -0
- package/node_modules/@html-eslint/eslint-plugin/package.json +7 -7
- package/node_modules/@html-eslint/eslint-plugin/types/rules/no-duplicate-attrs.d.ts.map +1 -1
- package/node_modules/@html-eslint/eslint-plugin/types/rules/no-duplicate-id.d.ts.map +1 -1
- package/node_modules/@html-eslint/eslint-plugin/types/rules/no-duplicate-in-head.d.ts.map +1 -1
- package/node_modules/@html-eslint/eslint-plugin/types/rules/utils/branch-segments.d.ts +71 -0
- package/node_modules/@html-eslint/eslint-plugin/types/rules/utils/branch-segments.d.ts.map +1 -0
- package/node_modules/@html-eslint/parser/lib/branch-annotation.js +282 -0
- package/node_modules/@html-eslint/parser/lib/options.js +47 -2
- package/node_modules/@html-eslint/parser/lib/parser.js +62 -1
- package/node_modules/@html-eslint/parser/lib/template-engine-syntax-preset.js +117 -2
- package/node_modules/@html-eslint/parser/package.json +4 -4
- package/node_modules/@html-eslint/parser/types/branch-annotation.d.ts +93 -0
- package/node_modules/@html-eslint/parser/types/branch-annotation.d.ts.map +1 -0
- package/node_modules/@html-eslint/parser/types/options.d.ts +12 -1
- package/node_modules/@html-eslint/parser/types/options.d.ts.map +1 -1
- package/node_modules/@html-eslint/parser/types/parser.d.ts.map +1 -1
- package/node_modules/@html-eslint/parser/types/template-engine-syntax-preset.d.ts +76 -2
- package/node_modules/@html-eslint/parser/types/template-engine-syntax-preset.d.ts.map +1 -1
- package/node_modules/@html-eslint/template-parser/package.json +3 -3
- package/node_modules/@html-eslint/template-syntax-parser/package.json +3 -3
- package/node_modules/@html-eslint/types/package.json +2 -2
- package/node_modules/@humanwhocodes/momoa/dist/momoa.cjs +14 -1
- package/node_modules/@humanwhocodes/momoa/dist/momoa.js +14 -1
- package/node_modules/@humanwhocodes/momoa/package.json +4 -4
- package/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.mjs +115 -71
- package/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.mjs.map +2 -2
- package/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js +115 -71
- package/node_modules/@jridgewell/sourcemap-codec/dist/sourcemap-codec.umd.js.map +2 -2
- package/node_modules/@jridgewell/sourcemap-codec/package.json +2 -1
- package/node_modules/@jridgewell/sourcemap-codec/src/range-mappings.ts +47 -0
- package/node_modules/@jridgewell/sourcemap-codec/src/scopes.ts +66 -46
- package/node_modules/@jridgewell/sourcemap-codec/src/sourcemap-codec.ts +27 -11
- package/node_modules/@jridgewell/sourcemap-codec/src/vlq.ts +13 -17
- package/node_modules/@jridgewell/sourcemap-codec/types/range-mappings.d.cts +5 -0
- package/node_modules/@jridgewell/sourcemap-codec/types/range-mappings.d.cts.map +1 -0
- package/node_modules/@jridgewell/sourcemap-codec/types/range-mappings.d.mts +5 -0
- package/node_modules/@jridgewell/sourcemap-codec/types/range-mappings.d.mts.map +1 -0
- package/node_modules/@jridgewell/sourcemap-codec/types/scopes.d.cts.map +1 -1
- package/node_modules/@jridgewell/sourcemap-codec/types/scopes.d.mts.map +1 -1
- package/node_modules/@jridgewell/sourcemap-codec/types/sourcemap-codec.d.cts +2 -0
- package/node_modules/@jridgewell/sourcemap-codec/types/sourcemap-codec.d.cts.map +1 -1
- package/node_modules/@jridgewell/sourcemap-codec/types/sourcemap-codec.d.mts +2 -0
- package/node_modules/@jridgewell/sourcemap-codec/types/sourcemap-codec.d.mts.map +1 -1
- package/node_modules/@jridgewell/sourcemap-codec/types/vlq.d.cts +4 -2
- package/node_modules/@jridgewell/sourcemap-codec/types/vlq.d.cts.map +1 -1
- package/node_modules/@jridgewell/sourcemap-codec/types/vlq.d.mts +4 -2
- package/node_modules/@jridgewell/sourcemap-codec/types/vlq.d.mts.map +1 -1
- package/node_modules/@rviscomi/capo.js/README.md +18 -6
- package/node_modules/@rviscomi/capo.js/dist/adapters/adapter.cjs +8 -0
- package/node_modules/@rviscomi/capo.js/dist/adapters/browser.cjs +26 -2
- package/node_modules/@rviscomi/capo.js/dist/adapters/index.cjs +26 -2
- package/node_modules/@rviscomi/capo.js/dist/analyzer.cjs +300 -263
- package/node_modules/@rviscomi/capo.js/dist/chrome/README.md +5 -1
- package/node_modules/@rviscomi/capo.js/dist/chrome/background.js +1 -1
- package/node_modules/@rviscomi/capo.js/dist/chrome/capo.css +4 -11
- package/node_modules/@rviscomi/capo.js/dist/chrome/capo.html +2 -2
- package/node_modules/@rviscomi/capo.js/dist/chrome/capo.js +3 -3
- package/node_modules/@rviscomi/capo.js/dist/chrome/chrome.js +2 -9
- package/node_modules/@rviscomi/capo.js/dist/chrome/manifest.json +1 -1
- package/node_modules/@rviscomi/capo.js/dist/chrome/options/options.html +1 -1
- package/node_modules/@rviscomi/capo.js/dist/chrome/options/options.js +1 -1
- package/node_modules/@rviscomi/capo.js/dist/chrome/styles/open-props.css +16 -14
- package/node_modules/@rviscomi/capo.js/dist/chrome.zip +0 -0
- package/node_modules/@rviscomi/capo.js/dist/firefox/README.md +5 -1
- package/node_modules/@rviscomi/capo.js/dist/firefox/background.js +1 -1
- package/node_modules/@rviscomi/capo.js/dist/firefox/capo.css +4 -11
- package/node_modules/@rviscomi/capo.js/dist/firefox/capo.html +2 -2
- package/node_modules/@rviscomi/capo.js/dist/firefox/capo.js +3 -3
- package/node_modules/@rviscomi/capo.js/dist/firefox/chrome.js +2 -9
- package/node_modules/@rviscomi/capo.js/dist/firefox/manifest.json +1 -1
- package/node_modules/@rviscomi/capo.js/dist/firefox/options/options.html +1 -1
- package/node_modules/@rviscomi/capo.js/dist/firefox/options/options.js +1 -1
- package/node_modules/@rviscomi/capo.js/dist/firefox/styles/open-props.css +16 -14
- package/node_modules/@rviscomi/capo.js/dist/firefox.zip +0 -0
- package/node_modules/@rviscomi/capo.js/dist/index.cjs +378 -368
- package/node_modules/@rviscomi/capo.js/dist/lib/colors.cjs +1 -1
- package/node_modules/@rviscomi/capo.js/dist/lib/io.cjs +7 -5
- package/node_modules/@rviscomi/capo.js/dist/lib/options.cjs +7 -3
- package/node_modules/@rviscomi/capo.js/dist/lib/rules.cjs +25 -4
- package/node_modules/@rviscomi/capo.js/dist/lib/validation.cjs +326 -358
- package/node_modules/@rviscomi/capo.js/dist/source.zip +0 -0
- package/node_modules/@rviscomi/capo.js/dist/types/adapters/adapter.d.ts +6 -0
- package/node_modules/@rviscomi/capo.js/dist/types/adapters/browser.d.ts +8 -1
- package/node_modules/@rviscomi/capo.js/dist/types/adapters/index.d.ts +2 -2
- package/node_modules/@rviscomi/capo.js/dist/types/analyzer.d.ts +5 -0
- package/node_modules/@rviscomi/capo.js/dist/types/index.d.ts +5 -5
- package/node_modules/@rviscomi/capo.js/dist/types/lib/options.d.ts +1 -1
- package/node_modules/@rviscomi/capo.js/dist/types/lib/rules.d.ts +9 -2
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validation.d.ts +4 -2
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/charset.d.ts +28 -0
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/content-type.d.ts +18 -0
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/csp.d.ts +12 -0
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/default-style.d.ts +18 -0
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/head-elements.d.ts +52 -0
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/http-equiv.d.ts +18 -0
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/origin-trial.d.ts +19 -0
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/preload.d.ts +41 -0
- package/node_modules/@rviscomi/capo.js/dist/types/lib/validations/viewport.d.ts +18 -0
- package/node_modules/@rviscomi/capo.js/dist/types/worker/worker.d.ts +16 -0
- package/node_modules/@rviscomi/capo.js/package.json +8 -12
- package/node_modules/@rviscomi/capo.js/src/adapters/adapter.js +37 -28
- package/node_modules/@rviscomi/capo.js/src/adapters/browser.js +41 -24
- package/node_modules/@rviscomi/capo.js/src/adapters/index.js +3 -3
- package/node_modules/@rviscomi/capo.js/src/adapters/test-suite.js +129 -129
- package/node_modules/@rviscomi/capo.js/src/analyzer.js +20 -25
- package/node_modules/@rviscomi/capo.js/src/extension/README.md +5 -1
- package/node_modules/@rviscomi/capo.js/src/extension/background.js +1 -1
- package/node_modules/@rviscomi/capo.js/src/extension/capo.css +4 -11
- package/node_modules/@rviscomi/capo.js/src/extension/capo.html +2 -2
- package/node_modules/@rviscomi/capo.js/src/extension/capo.js +21 -18
- package/node_modules/@rviscomi/capo.js/src/extension/chrome.js +2 -9
- package/node_modules/@rviscomi/capo.js/src/extension/manifest.json +2 -6
- package/node_modules/@rviscomi/capo.js/src/extension/options/options.html +1 -1
- package/node_modules/@rviscomi/capo.js/src/extension/options.js +16 -16
- package/node_modules/@rviscomi/capo.js/src/extension/styles/open-props.css +16 -14
- package/node_modules/@rviscomi/capo.js/src/index.js +10 -20
- package/node_modules/@rviscomi/capo.js/src/lib/colors.js +17 -17
- package/node_modules/@rviscomi/capo.js/src/lib/io.js +19 -17
- package/node_modules/@rviscomi/capo.js/src/lib/options.js +23 -20
- package/node_modules/@rviscomi/capo.js/src/lib/rules.js +124 -95
- package/node_modules/@rviscomi/capo.js/src/lib/validation.js +57 -857
- package/node_modules/@rviscomi/capo.js/src/lib/validations/content-type.js +94 -0
- package/node_modules/@rviscomi/capo.js/src/lib/validations/csp.js +68 -0
- package/node_modules/@rviscomi/capo.js/src/lib/validations/default-style.js +62 -0
- package/node_modules/@rviscomi/capo.js/src/lib/validations/http-equiv.js +138 -0
- package/node_modules/@rviscomi/capo.js/src/lib/validations/origin-trial.js +80 -0
- package/node_modules/@rviscomi/capo.js/src/lib/validations/preload.js +135 -0
- package/node_modules/@rviscomi/capo.js/src/lib/validations/viewport.js +183 -0
- package/node_modules/@rviscomi/capo.js/src/web/capo.js +12 -12
- package/node_modules/@rviscomi/capo.js/src/worker/worker.js +180 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslint-recommended-raw.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslint-recommended-raw.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/all.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/base.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/disable-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/eslint-recommended.d.ts +1 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/eslint-recommended.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/recommended-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/recommended-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/recommended.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/strict-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/strict-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/strict.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/stylistic-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/stylistic-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/eslintrc/stylistic.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/all.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/all.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/base.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/base.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/disable-type-checked.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/disable-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/eslint-recommended.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/eslint-recommended.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended-type-checked-only.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended-type-checked.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/recommended.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict-type-checked-only.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict-type-checked.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/strict.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic-type-checked-only.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic-type-checked-only.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic-type-checked.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic-type-checked.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/configs/flat/stylistic.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/index.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/raw-plugin.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/raw-plugin.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/adjacent-overload-signatures.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/array-type.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/await-thenable.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/ban-ts-comment.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/ban-tslint-comment.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/class-literal-property-style.js +12 -4
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/class-methods-use-this.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-generic-constructors.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-indexed-object-style.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-return.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-assertions.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-definitions.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-exports.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-imports.d.ts +2 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/consistent-type-imports.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/default-param-last.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/dot-notation.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/enum-utils/shared.d.ts +5 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/enum-utils/shared.js +68 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/explicit-function-return-type.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/explicit-member-accessibility.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/explicit-module-boundary-types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/index.d.ts +1 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/index.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/init-declarations.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/max-params.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/member-ordering.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/method-signature-style.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/enums.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/format.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/parse-options.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/schema.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/shared.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention-utils/validator.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/naming-convention.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-array-constructor.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-array-delete.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-base-to-string.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-confusing-non-null-assertion.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-confusing-void-expression.js +8 -9
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-deprecated.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-dupe-class-members.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-duplicate-enum-values.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-duplicate-type-constituents.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-dynamic-delete.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-empty-function.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-empty-interface.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-empty-object-type.js +9 -4
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-explicit-any.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-extra-non-null-assertion.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-extraneous-class.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-floating-promises.js +64 -55
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-for-in-array.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-implied-eval.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-import-type-side-effects.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-inferrable-types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-invalid-this.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-invalid-void-type.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-loop-func.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-loss-of-precision.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-magic-numbers.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-meaningless-void-operator.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-misused-new.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-misused-promises.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-misused-spread.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-mixed-enums.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-namespace.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-non-null-asserted-nullish-coalescing.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-non-null-asserted-optional-chain.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-non-null-assertion.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-redeclare.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-redundant-type-constituents.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-require-imports.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-restricted-imports.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-restricted-types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-shadow.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-this-alias.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-type-alias.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-boolean-literal-compare.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-condition.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-parameter-property-assignment.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-qualifier.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-template-expression.js +3 -14
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-arguments.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-assertion.d.ts +1 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-assertion.js +14 -39
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-constraint.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-conversion.js +2 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unnecessary-type-parameters.js +6 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-argument.js +2 -91
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-assignment.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-call.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-declaration-merging.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-enum-comparison.js +3 -113
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-function-type.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-member-access.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-return.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-type-assertion.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unsafe-unary-minus.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unused-expressions.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unused-private-class-members.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-unused-vars.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-use-before-define.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-useless-constructor.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-useless-default-assignment.js +15 -11
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-useless-empty-export.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-var-requires.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/no-wrapper-object-types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/non-nullable-type-assertion-style.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/only-throw-error.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/parameter-properties.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-as-const.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-destructuring.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-enum-initializers.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-find.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-for-of.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-function-type.d.ts +2 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-function-type.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-includes.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-literal-enum-member.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-namespace-keyword.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-nullish-coalescing.js +2 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/PreferOptionalChainOptions.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/analyzeChain.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/checkNullishAndReport.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/compareNodes.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain-utils/gatherLogicalOperands.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-optional-chain.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-promise-reject-errors.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-readonly-parameter-types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-readonly.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-reduce-type-parameter.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-regexp-exec.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-return-this-type.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-string-starts-ends-with.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/prefer-ts-expect-error.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/promise-function-async.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/related-getter-setter-pairs.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/require-array-sort-compare.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/require-await.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/restrict-plus-operands.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/restrict-template-expressions.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/return-await.js +13 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/sort-type-constituents.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/strict-boolean-expressions.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/strict-void-return.d.ts +3 -2
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/strict-void-return.js +97 -5
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/switch-exhaustiveness-check.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/triple-slash-reference.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/typedef.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/unbound-method.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/unified-signatures.d.ts +1 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/unified-signatures.js +73 -32
- package/node_modules/@typescript-eslint/eslint-plugin/dist/rules/use-unknown-in-catch-callback-variable.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/FunctionSignature.d.ts +15 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/FunctionSignature.js +123 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/assertionFunctionUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/astUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/baseTypeUtils.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/baseTypeUtils.js +17 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/class-scope-analyzer/classScopeAnalyzer.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/class-scope-analyzer/extractComputedName.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/class-scope-analyzer/types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/collectUnusedVariables.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/createRule.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/escapeRegExp.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/explicitReturnTypeUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getBaseTypesOfClassMember.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getConstraintInfo.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getESLintCoreRule.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getFixOrSuggest.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getForStatementHeadLoc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getFunctionHeadLoc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getMemberHeadLoc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getOperatorPrecedence.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getParentFunctionNode.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getStaticStringValue.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getStringLength.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getTextWithParentheses.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getThisExpression.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getValueOfLiteralType.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getWrappedCode.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/getWrappingFixer.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/hasOverloadSignatures.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/index.d.ts +3 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/index.js +4 -1
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isArrayMethodCallWithPredicate.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isAssignee.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isConditionalTest.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isHigherPrecedenceThanAwait.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isNodeEqual.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isNullLiteral.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isPromiseAggregatorMethod.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isStartOfArrowFunctionBody.d.ts +2 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isStartOfArrowFunctionBody.js +26 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isStartOfExpressionStatement.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isTypeImport.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/isUndefinedIdentifier.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/misc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/needsPrecedingSemiColon.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/needsToBeAwaited.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/objectIterators.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/promiseUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/rangeToLoc.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/referenceContainsTypePredicate.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/referenceContainsTypeQuery.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/scopeUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/skipChainExpression.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/truthinessUtils.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/types.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/dist/util/walkStatements.js +1 -0
- package/node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore/README.md +52 -0
- package/node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore/index.js +785 -129
- package/node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore/legacy.js +660 -98
- package/node_modules/@typescript-eslint/eslint-plugin/node_modules/ignore/package.json +10 -4
- package/node_modules/@typescript-eslint/eslint-plugin/package.json +13 -12
- package/node_modules/@typescript-eslint/parser/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/parser/dist/parser.js +1 -0
- package/node_modules/@typescript-eslint/parser/package.json +8 -7
- package/node_modules/@typescript-eslint/project-service/dist/createProjectService.js +1 -0
- package/node_modules/@typescript-eslint/project-service/dist/getParsedConfigFileFromTSServer.js +1 -0
- package/node_modules/@typescript-eslint/project-service/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/project-service/package.json +6 -5
- package/node_modules/@typescript-eslint/scope-manager/dist/ID.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/ScopeManager.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/analyze.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/assert.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/CatchClauseDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/ClassNameDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/Definition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/DefinitionBase.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/DefinitionType.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/FunctionNameDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/ImplicitGlobalVariableDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/ImportBindingDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/ParameterDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/TSEnumMemberDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/TSEnumNameDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/TSModuleNameDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/TypeDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/VariableDefinition.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/definition/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/base-config.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/decorators.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/decorators.legacy.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/dom.asynciterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/dom.iterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/dom.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.core.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.generator.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.iterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.proxy.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.reflect.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.symbol.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2015.symbol.wellknown.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2016.array.include.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2016.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2016.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2016.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.arraybuffer.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.date.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.sharedmemory.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2017.typedarrays.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.asyncgenerator.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.asynciterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2018.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.array.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2019.symbol.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.bigint.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.date.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.number.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.sharedmemory.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2020.symbol.wellknown.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2021.weakref.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.array.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.error.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2022.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.array.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2023.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.arraybuffer.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.sharedmemory.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2024.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.float16.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.iterator.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es2025.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es5.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es6.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/es7.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.array.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.asynciterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.bigint.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.collection.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.date.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.decorators.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.disposable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.error.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.float16.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.full.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.intl.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.iterator.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.object.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.promise.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.regexp.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.sharedmemory.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.string.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.symbol.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.temporal.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.typedarrays.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/esnext.weakref.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/lib.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/scripthost.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/webworker.asynciterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/webworker.importscripts.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/webworker.iterable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/lib/webworker.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/ClassVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/ExportVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/ImportVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/PatternVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/Reference.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/Referencer.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/TypeVisitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/Visitor.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/VisitorBase.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/referencer/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/BlockScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/CatchScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ClassFieldInitializerScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ClassScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ClassStaticBlockScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ConditionalTypeScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ForScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/FunctionExpressionNameScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/FunctionScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/FunctionTypeScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/GlobalScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/MappedTypeScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ModuleScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/Scope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ScopeBase.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/ScopeType.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/SwitchScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/TSEnumScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/TSModuleScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/TypeScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/WithScope.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/scope/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/ESLintScopeVariable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/ImplicitLibVariable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/Variable.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/VariableBase.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/dist/variable/index.js +1 -0
- package/node_modules/@typescript-eslint/scope-manager/package.json +8 -7
- package/node_modules/@typescript-eslint/tsconfig-utils/dist/compilerOptions.js +1 -0
- package/node_modules/@typescript-eslint/tsconfig-utils/dist/getParsedConfigFile.js +1 -0
- package/node_modules/@typescript-eslint/tsconfig-utils/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/tsconfig-utils/package.json +3 -2
- package/node_modules/@typescript-eslint/type-utils/dist/TypeOrValueSpecifier.d.ts +19 -19
- package/node_modules/@typescript-eslint/type-utils/dist/TypeOrValueSpecifier.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/builtinSymbolLikes.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/containsAllTypesByName.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/discriminateAnyType.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getConstrainedTypeAtLocation.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getContextualType.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getDeclaration.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getSourceFileOfNode.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/getTypeName.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/isSymbolFromDefaultLibrary.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/isTypeBrandedLiteralLike.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/isTypeReadonly.d.ts +19 -19
- package/node_modules/@typescript-eslint/type-utils/dist/isTypeReadonly.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/isUnsafeAssignment.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/predicates.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/propertyTypes.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/requiresQuoting.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeFlagUtils.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/specifierNameMatches.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/typeDeclaredInFile.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/typeDeclaredInLib.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/dist/typeOrValueSpecifiers/typeDeclaredInPackageDeclarationFile.js +1 -0
- package/node_modules/@typescript-eslint/type-utils/package.json +9 -8
- package/node_modules/@typescript-eslint/types/dist/generated/ast-spec.d.ts +9 -0
- package/node_modules/@typescript-eslint/types/dist/generated/ast-spec.js +1 -0
- package/node_modules/@typescript-eslint/types/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/types/dist/lib.js +1 -0
- package/node_modules/@typescript-eslint/types/dist/parser-options.js +1 -0
- package/node_modules/@typescript-eslint/types/dist/ts-estree.js +1 -0
- package/node_modules/@typescript-eslint/types/package.json +3 -5
- package/node_modules/@typescript-eslint/typescript-estree/dist/ast-converter.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/check-modifiers.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/check-syntax-errors.js +15 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/clear-caches.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert-comments.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/convert.js +25 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/WatchCompilerHostOfConfigFile.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createIsolatedProgram.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgram.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createProjectProgramError.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/createSourceFile.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/describeFilePath.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getScriptKind.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/getWatchProgramsForProjects.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/shared.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/useProvidedPrograms.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/create-program/validateDefaultProjectForFilesGlob.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/createParserServices.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/getImportClausePhaseModifier.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/getModifiers.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/jsx/xhtml-entities.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/node-utils.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/ExpiringCache.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/candidateTSConfigRootDirs.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/createParseSettings.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/getProjectConfigFiles.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/index.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/inferSingleRun.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/resolveProjectList.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parseSettings/warnAboutTSVersion.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parser-options.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/parser.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/semantic-or-syntactic-errors.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/simple-traverse.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/source-files.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/estree-to-ts-node-types.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/index.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/ts-estree/ts-nodes.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/use-at-your-own-risk.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/useProgramFromProjectService.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/version-check.d.ts +1 -1
- package/node_modules/@typescript-eslint/typescript-estree/dist/version-check.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/version.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/dist/withoutProjectParserOptions.js +1 -0
- package/node_modules/@typescript-eslint/typescript-estree/package.json +8 -7
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/PatternMatcher.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/ReferenceTracker.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/astUtilities.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/predicates.d.ts +20 -20
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/predicates.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/eslint-utils/scopeAnalysis.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/helpers.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/misc.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/predicates.d.ts +1 -1
- package/node_modules/@typescript-eslint/utils/dist/ast-utils/predicates.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/InferTypesFromRule.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/RuleCreator.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/applyDefault.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/deepMerge.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/getParserServices.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/nullThrows.d.ts +1 -1
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/nullThrows.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/eslint-utils/parserSeemsToBeTSESLint.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/json-schema.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/AST.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Config.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/ESLint.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Linter.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Parser.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/ParserOptions.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Processor.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Rule.d.ts +17 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Rule.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/RuleTester.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/Scope.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/SourceCode.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/eslint/ESLintShared.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/eslint/FlatESLint.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/eslint/LegacyESLint.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-eslint/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-estree.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-utils/NoInfer.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-utils/index.js +1 -0
- package/node_modules/@typescript-eslint/utils/dist/ts-utils/isArray.js +1 -0
- package/node_modules/@typescript-eslint/utils/package.json +6 -5
- package/node_modules/@typescript-eslint/visitor-keys/dist/get-keys.js +1 -0
- package/node_modules/@typescript-eslint/visitor-keys/dist/index.js +1 -0
- package/node_modules/@typescript-eslint/visitor-keys/dist/visitor-keys.js +1 -0
- package/node_modules/@typescript-eslint/visitor-keys/package.json +5 -4
- package/node_modules/astro-eslint-parser/lib/index.mjs +13 -37
- package/node_modules/astro-eslint-parser/package.json +7 -7
- package/node_modules/eslint/README.md +1 -6
- package/node_modules/eslint/lib/config/config-loader.js +2 -2
- package/node_modules/eslint/lib/config/config.js +2 -2
- package/node_modules/eslint/lib/eslint/eslint.js +1 -1
- package/node_modules/eslint/lib/languages/js/index.js +1 -1
- package/node_modules/eslint/lib/options.js +2 -2
- package/node_modules/eslint/lib/rules/accessor-pairs.js +1 -51
- package/node_modules/eslint/lib/rules/getter-return.js +4 -45
- package/node_modules/eslint/lib/rules/id-denylist.js +4 -0
- package/node_modules/eslint/lib/rules/id-match.js +2 -1
- package/node_modules/eslint/lib/rules/no-duplicate-imports.js +3 -3
- package/node_modules/eslint/lib/rules/no-loss-of-precision.js +7 -2
- package/node_modules/eslint/lib/rules/no-setter-return.js +1 -89
- package/node_modules/eslint/lib/rules/no-unmodified-loop-condition.js +21 -5
- package/node_modules/eslint/lib/rules/no-unused-labels.js +19 -0
- package/node_modules/eslint/lib/rules/no-unused-vars.js +115 -8
- package/node_modules/eslint/lib/rules/no-useless-escape.js +2 -2
- package/node_modules/eslint/lib/rules/no-var.js +87 -1
- package/node_modules/eslint/lib/rules/prefer-template.js +7 -1
- package/node_modules/eslint/lib/rules/utils/ast-utils.js +86 -0
- package/node_modules/eslint/lib/types/index.d.ts +1 -1
- package/node_modules/eslint/lib/types/rules.d.ts +10 -1
- package/node_modules/eslint/messages/config-file-missing.js +2 -2
- package/node_modules/eslint/package.json +9 -3
- package/node_modules/eslint-plugin-astro/README.md +22 -1
- package/node_modules/eslint-plugin-astro/lib/index.mjs +24 -19
- package/node_modules/eslint-plugin-astro/package.json +8 -4
- package/node_modules/eslint-plugin-yml/lib/index.mjs +220 -78
- package/node_modules/eslint-plugin-yml/package.json +5 -4
- package/node_modules/globals/globals.json +75 -0
- package/node_modules/globals/index.d.ts +77 -0
- package/node_modules/globals/package.json +2 -2
- package/node_modules/nanoid/README.md +3 -0
- package/node_modules/nanoid/async/index.browser.cjs +1 -0
- package/node_modules/nanoid/async/index.browser.js +1 -0
- package/node_modules/nanoid/async/index.cjs +4 -1
- package/node_modules/nanoid/async/index.js +4 -1
- package/node_modules/nanoid/async/index.native.js +4 -1
- package/node_modules/nanoid/index.browser.cjs +1 -0
- package/node_modules/nanoid/index.browser.js +1 -0
- package/node_modules/nanoid/index.cjs +1 -0
- package/node_modules/nanoid/index.js +1 -0
- package/node_modules/nanoid/package.json +1 -1
- package/node_modules/picomatch/lib/parse.js +10 -1
- package/node_modules/picomatch/lib/scan.js +30 -18
- package/node_modules/picomatch/package.json +1 -1
- package/node_modules/postcss/README.md +4 -1
- package/node_modules/postcss/lib/list.js +1 -1
- package/node_modules/postcss/lib/previous-map.js +14 -2
- package/node_modules/postcss/lib/processor.js +1 -1
- package/node_modules/postcss/package.json +2 -2
- package/node_modules/postcss-selector-parser/CHANGELOG.md +74 -65
- package/node_modules/postcss-selector-parser/dist/parser.js +25 -3
- package/node_modules/postcss-selector-parser/package.json +6 -3
- package/node_modules/typescript-eslint/dist/compatibility-types.js +1 -0
- package/node_modules/typescript-eslint/dist/config-helper.js +1 -0
- package/node_modules/typescript-eslint/dist/getTSConfigRootDirFromStack.js +1 -0
- package/node_modules/typescript-eslint/dist/globs.d.ts +123 -0
- package/node_modules/typescript-eslint/dist/globs.js +135 -0
- package/node_modules/typescript-eslint/dist/index.d.ts +12 -0
- package/node_modules/typescript-eslint/dist/index.js +8 -1
- package/node_modules/typescript-eslint/package.json +8 -6
- package/node_modules/vscode-languageserver-textdocument/eslint.config.js +13 -0
- package/node_modules/vscode-languageserver-textdocument/lib/esm/main.d.ts +20 -0
- package/node_modules/vscode-languageserver-textdocument/lib/esm/main.js +26 -0
- package/node_modules/vscode-languageserver-textdocument/lib/umd/main.d.ts +20 -0
- package/node_modules/vscode-languageserver-textdocument/lib/umd/main.js +26 -0
- package/node_modules/vscode-languageserver-textdocument/package.json +2 -2
- package/node_modules/vscode-uri/lib/esm/index.mjs +1 -1
- package/node_modules/vscode-uri/lib/esm/index.mjs.map +1 -1
- package/node_modules/vscode-uri/lib/umd/index.d.ts +5 -0
- package/node_modules/vscode-uri/lib/umd/index.js +1 -1
- package/node_modules/vscode-uri/lib/umd/index.js.map +1 -1
- package/node_modules/vscode-uri/package.json +5 -1
- package/package.json +12 -12
|
@@ -1,14 +1,26 @@
|
|
|
1
|
-
import { isMetaCSP, isOriginTrial } from
|
|
1
|
+
import { isMetaCSP, isOriginTrial } from "./rules.js";
|
|
2
|
+
import { validateCSP } from "./validations/csp.js";
|
|
3
|
+
import { validateOriginTrial } from "./validations/origin-trial.js";
|
|
4
|
+
import { isDefaultStyle, validateDefaultStyle } from "./validations/default-style.js";
|
|
5
|
+
import { isContentType, validateContentType } from "./validations/content-type.js";
|
|
6
|
+
import { isHttpEquiv, validateHttpEquiv } from "./validations/http-equiv.js";
|
|
7
|
+
import { isMetaViewport, validateMetaViewport } from "./validations/viewport.js";
|
|
8
|
+
import {
|
|
9
|
+
isUnnecessaryPreload,
|
|
10
|
+
validateUnnecessaryPreload,
|
|
11
|
+
isInvalidFontPreload,
|
|
12
|
+
validateInvalidFontPreload,
|
|
13
|
+
} from "./validations/preload.js";
|
|
2
14
|
|
|
3
15
|
/**
|
|
4
16
|
* @typedef {import('../adapters/adapter.js').AdapterInterface} AdapterInterface
|
|
5
|
-
*
|
|
17
|
+
*
|
|
6
18
|
* @typedef {Object} ValidationWarningResult
|
|
7
19
|
* @property {string} ruleId
|
|
8
20
|
* @property {string} warning
|
|
9
21
|
* @property {any} [element]
|
|
10
22
|
* @property {any[]} [elements]
|
|
11
|
-
*
|
|
23
|
+
*
|
|
12
24
|
* @typedef {Object} CustomValidationResult
|
|
13
25
|
* @property {string} [ruleId]
|
|
14
26
|
* @property {string[]} [warnings]
|
|
@@ -42,7 +54,7 @@ export const PRELOAD_SELECTOR = 'link:is([rel="preload" i], [rel="modulepreload"
|
|
|
42
54
|
export function isValidElement(element, adapter) {
|
|
43
55
|
const tagName = adapter.getTagName(element);
|
|
44
56
|
// Text nodes and comment nodes are valid (they don't have tag names)
|
|
45
|
-
if (!tagName || tagName ===
|
|
57
|
+
if (!tagName || tagName === "") {
|
|
46
58
|
return true;
|
|
47
59
|
}
|
|
48
60
|
return VALID_HEAD_ELEMENTS.has(tagName.toLowerCase());
|
|
@@ -56,7 +68,7 @@ export function isValidElement(element, adapter) {
|
|
|
56
68
|
*/
|
|
57
69
|
function hasInvalidChildren(element, adapter) {
|
|
58
70
|
const children = adapter.getChildren(element);
|
|
59
|
-
return children.some(child => !isValidElement(child, adapter));
|
|
71
|
+
return children.some((child) => !isValidElement(child, adapter));
|
|
60
72
|
}
|
|
61
73
|
|
|
62
74
|
/**
|
|
@@ -66,7 +78,7 @@ function hasInvalidChildren(element, adapter) {
|
|
|
66
78
|
* @returns {boolean}
|
|
67
79
|
*/
|
|
68
80
|
function isDuplicateTitle(element, adapter) {
|
|
69
|
-
if (adapter.getTagName(element) !==
|
|
81
|
+
if (adapter.getTagName(element) !== "title") {
|
|
70
82
|
return false;
|
|
71
83
|
}
|
|
72
84
|
const parent = adapter.getParent(element);
|
|
@@ -76,7 +88,7 @@ function isDuplicateTitle(element, adapter) {
|
|
|
76
88
|
// Check if this is the first title element
|
|
77
89
|
let foundFirst = false;
|
|
78
90
|
for (const child of adapter.getChildren(parent)) {
|
|
79
|
-
if (adapter.getTagName(child) ===
|
|
91
|
+
if (adapter.getTagName(child) === "title") {
|
|
80
92
|
if (child === element) {
|
|
81
93
|
// This is the element we're checking - it's a duplicate if we already found a title
|
|
82
94
|
return foundFirst;
|
|
@@ -95,20 +107,21 @@ function isDuplicateTitle(element, adapter) {
|
|
|
95
107
|
* @returns {boolean}
|
|
96
108
|
*/
|
|
97
109
|
function isDuplicateBase(element, adapter) {
|
|
98
|
-
if (adapter.getTagName(element) !==
|
|
110
|
+
if (adapter.getTagName(element) !== "base") {
|
|
99
111
|
return false;
|
|
100
112
|
}
|
|
101
113
|
const siblings = adapter.getSiblings(element);
|
|
102
|
-
return siblings.some(sibling => adapter.getTagName(sibling) ===
|
|
114
|
+
return siblings.some((sibling) => adapter.getTagName(sibling) === "base");
|
|
103
115
|
}
|
|
104
116
|
|
|
105
117
|
/**
|
|
106
118
|
* Check if an element has any validation warning
|
|
107
119
|
* @param {any} element
|
|
108
120
|
* @param {AdapterInterface} adapter
|
|
121
|
+
* @param {string|null} [pageOrigin=null]
|
|
109
122
|
* @returns {boolean}
|
|
110
123
|
*/
|
|
111
|
-
export function hasValidationWarning(element, adapter) {
|
|
124
|
+
export function hasValidationWarning(element, adapter, pageOrigin = null) {
|
|
112
125
|
// Element itself is not valid.
|
|
113
126
|
if (!isValidElement(element, adapter)) {
|
|
114
127
|
return true;
|
|
@@ -129,44 +142,22 @@ export function hasValidationWarning(element, adapter) {
|
|
|
129
142
|
return true;
|
|
130
143
|
}
|
|
131
144
|
|
|
132
|
-
//
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
if (isInvalidDefaultStyle(element, adapter)) {
|
|
149
|
-
return true;
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
// Invalid character encoding.
|
|
153
|
-
if (isInvalidContentType(element, adapter)) {
|
|
154
|
-
return true;
|
|
155
|
-
}
|
|
156
|
-
|
|
157
|
-
// Origin trial expired, or invalid origin.
|
|
158
|
-
if (isInvalidOriginTrial(element, adapter)) {
|
|
159
|
-
return true;
|
|
160
|
-
}
|
|
161
|
-
|
|
162
|
-
// Preload is unnecessary.
|
|
163
|
-
if (isUnnecessaryPreload(element, adapter)) {
|
|
164
|
-
return true;
|
|
165
|
-
}
|
|
166
|
-
|
|
167
|
-
// Preload is missing crossorigin.
|
|
168
|
-
if (isInvalidFontPreload(element, adapter)) {
|
|
169
|
-
return true;
|
|
145
|
+
// For other checks, we reuse getCustomValidations logic to avoid computing twice.
|
|
146
|
+
// We only run validations for elements that match specific rules.
|
|
147
|
+
if (
|
|
148
|
+
isOriginTrial(element, adapter) ||
|
|
149
|
+
isMetaCSP(element, adapter) ||
|
|
150
|
+
isDefaultStyle(element, adapter) ||
|
|
151
|
+
isMetaViewport(element, adapter) ||
|
|
152
|
+
isContentType(element, adapter) ||
|
|
153
|
+
isHttpEquiv(element, adapter) ||
|
|
154
|
+
isUnnecessaryPreload(element, adapter) ||
|
|
155
|
+
isInvalidFontPreload(element, adapter)
|
|
156
|
+
) {
|
|
157
|
+
const validations = getCustomValidations(element, adapter, null, pageOrigin);
|
|
158
|
+
if (validations.warnings && validations.warnings.length > 0) {
|
|
159
|
+
return true;
|
|
160
|
+
}
|
|
170
161
|
}
|
|
171
162
|
|
|
172
163
|
return false;
|
|
@@ -186,36 +177,36 @@ export function getValidationWarnings(head, adapter) {
|
|
|
186
177
|
const children = adapter.getChildren(head);
|
|
187
178
|
|
|
188
179
|
// Check for title elements
|
|
189
|
-
const titleElements = children.filter(child => adapter.getTagName(child) ===
|
|
180
|
+
const titleElements = children.filter((child) => adapter.getTagName(child) === "title");
|
|
190
181
|
const titleElementCount = titleElements.length;
|
|
191
|
-
if (titleElementCount
|
|
182
|
+
if (titleElementCount !== 1) {
|
|
192
183
|
validationWarnings.push({
|
|
193
|
-
ruleId: titleElementCount === 0 ?
|
|
184
|
+
ruleId: titleElementCount === 0 ? "require-title" : "no-duplicate-title",
|
|
194
185
|
warning: `Expected exactly 1 <title> element, found ${titleElementCount}`,
|
|
195
186
|
elements: titleElements,
|
|
196
187
|
});
|
|
197
188
|
}
|
|
198
189
|
|
|
199
190
|
// Check for meta viewport
|
|
200
|
-
const metaViewport = children.filter(child => {
|
|
201
|
-
if (adapter.getTagName(child) !==
|
|
202
|
-
const name = adapter.getAttribute(child,
|
|
203
|
-
return name && name.toLowerCase() ===
|
|
191
|
+
const metaViewport = children.filter((child) => {
|
|
192
|
+
if (adapter.getTagName(child) !== "meta") return false;
|
|
193
|
+
const name = adapter.getAttribute(child, "name");
|
|
194
|
+
return name && name.toLowerCase() === "viewport";
|
|
204
195
|
});
|
|
205
|
-
if (metaViewport.length
|
|
196
|
+
if (metaViewport.length !== 1) {
|
|
206
197
|
validationWarnings.push({
|
|
207
|
-
ruleId: metaViewport.length === 0 ?
|
|
198
|
+
ruleId: metaViewport.length === 0 ? "require-meta-viewport" : "valid-meta-viewport",
|
|
208
199
|
warning: `Expected exactly 1 <meta name=viewport> element, found ${metaViewport.length}`,
|
|
209
200
|
elements: metaViewport,
|
|
210
201
|
});
|
|
211
202
|
}
|
|
212
203
|
|
|
213
204
|
// Check for base elements
|
|
214
|
-
const baseElements = children.filter(child => adapter.getTagName(child) ===
|
|
205
|
+
const baseElements = children.filter((child) => adapter.getTagName(child) === "base");
|
|
215
206
|
const baseElementCount = baseElements.length;
|
|
216
207
|
if (baseElementCount > 1) {
|
|
217
208
|
validationWarnings.push({
|
|
218
|
-
ruleId:
|
|
209
|
+
ruleId: "no-duplicate-base",
|
|
219
210
|
warning: `Expected at most 1 <base> element, found ${baseElementCount}`,
|
|
220
211
|
elements: baseElements,
|
|
221
212
|
});
|
|
@@ -228,7 +219,7 @@ export function getValidationWarnings(head, adapter) {
|
|
|
228
219
|
elementChildren.forEach((child) => {
|
|
229
220
|
if (!isValidElement(child, adapter)) {
|
|
230
221
|
validationWarnings.push({
|
|
231
|
-
ruleId:
|
|
222
|
+
ruleId: "no-invalid-head-elements",
|
|
232
223
|
warning: `${adapter.getTagName(child).toUpperCase()} elements are not allowed in the <head>`,
|
|
233
224
|
element: element,
|
|
234
225
|
});
|
|
@@ -238,7 +229,7 @@ export function getValidationWarnings(head, adapter) {
|
|
|
238
229
|
}
|
|
239
230
|
|
|
240
231
|
validationWarnings.push({
|
|
241
|
-
ruleId:
|
|
232
|
+
ruleId: "no-invalid-head-elements",
|
|
242
233
|
warning: `${adapter.getTagName(element)} elements are not allowed in the <head>`,
|
|
243
234
|
element: element,
|
|
244
235
|
});
|
|
@@ -252,14 +243,15 @@ export function getValidationWarnings(head, adapter) {
|
|
|
252
243
|
* @param {any} element
|
|
253
244
|
* @param {AdapterInterface} adapter
|
|
254
245
|
* @param {any} [parentElement=null]
|
|
246
|
+
* @param {string|null} [pageOrigin=null]
|
|
255
247
|
* @returns {CustomValidationResult}
|
|
256
248
|
*/
|
|
257
|
-
export function getCustomValidations(element, adapter, parentElement = null) {
|
|
249
|
+
export function getCustomValidations(element, adapter, parentElement = null, pageOrigin = null) {
|
|
258
250
|
/** @type {CustomValidationResult[]} */
|
|
259
251
|
const results = [];
|
|
260
252
|
|
|
261
253
|
if (isOriginTrial(element, adapter)) {
|
|
262
|
-
results.push(validateOriginTrial(element, adapter));
|
|
254
|
+
results.push(validateOriginTrial(element, adapter, pageOrigin));
|
|
263
255
|
}
|
|
264
256
|
|
|
265
257
|
if (isMetaCSP(element, adapter)) {
|
|
@@ -303,9 +295,9 @@ export function getCustomValidations(element, adapter, parentElement = null) {
|
|
|
303
295
|
const combined = {
|
|
304
296
|
warnings: [],
|
|
305
297
|
payload: {},
|
|
306
|
-
ruleId: results[0].ruleId
|
|
298
|
+
ruleId: results[0].ruleId,
|
|
307
299
|
};
|
|
308
|
-
results.forEach(result => {
|
|
300
|
+
results.forEach((result) => {
|
|
309
301
|
if (result.warnings) {
|
|
310
302
|
combined.warnings?.push(...result.warnings);
|
|
311
303
|
}
|
|
@@ -315,795 +307,3 @@ export function getCustomValidations(element, adapter, parentElement = null) {
|
|
|
315
307
|
});
|
|
316
308
|
return combined;
|
|
317
309
|
}
|
|
318
|
-
|
|
319
|
-
/**
|
|
320
|
-
* @param {any} element
|
|
321
|
-
* @param {AdapterInterface} adapter
|
|
322
|
-
* @returns {CustomValidationResult}
|
|
323
|
-
*/
|
|
324
|
-
function validateCSP(element, adapter) {
|
|
325
|
-
/** @type {string[]} */
|
|
326
|
-
const warnings = [];
|
|
327
|
-
/** @type {any} */
|
|
328
|
-
let payload = null;
|
|
329
|
-
|
|
330
|
-
const httpEquiv = adapter.getAttribute(element, 'http-equiv');
|
|
331
|
-
const httpEquivLower = httpEquiv?.toLowerCase();
|
|
332
|
-
|
|
333
|
-
if (httpEquivLower === 'content-security-policy-report-only') {
|
|
334
|
-
warnings.push("CSP Report-Only is forbidden in meta tags");
|
|
335
|
-
return {
|
|
336
|
-
ruleId: 'no-meta-csp',
|
|
337
|
-
warnings,
|
|
338
|
-
payload,
|
|
339
|
-
};
|
|
340
|
-
}
|
|
341
|
-
|
|
342
|
-
if (httpEquivLower === 'content-security-policy') {
|
|
343
|
-
warnings.push("meta CSP discouraged. See https://crbug.com/1458493.");
|
|
344
|
-
}
|
|
345
|
-
|
|
346
|
-
const content = adapter.getAttribute(element, "content");
|
|
347
|
-
if (!content) {
|
|
348
|
-
warnings.push("Invalid CSP. The content attribute must be set.");
|
|
349
|
-
return { warnings, payload };
|
|
350
|
-
}
|
|
351
|
-
|
|
352
|
-
/** @type {Record<string, string>} */
|
|
353
|
-
const directives = Object.fromEntries(
|
|
354
|
-
content.split(/\s*;\s*/).map((directive) => {
|
|
355
|
-
const [key, ...value] = directive.split(" ");
|
|
356
|
-
return [key, value.join(" ")];
|
|
357
|
-
})
|
|
358
|
-
);
|
|
359
|
-
payload = payload ?? {};
|
|
360
|
-
payload.directives = directives;
|
|
361
|
-
|
|
362
|
-
if ("report-uri" in directives) {
|
|
363
|
-
warnings.push(
|
|
364
|
-
"The report-uri directive is not supported. Use the Content-Security-Policy-Report-Only HTTP header instead."
|
|
365
|
-
);
|
|
366
|
-
}
|
|
367
|
-
if ("frame-ancestors" in directives) {
|
|
368
|
-
warnings.push(
|
|
369
|
-
"The frame-ancestors directive is not supported. Use the Content-Security-Policy HTTP header instead."
|
|
370
|
-
);
|
|
371
|
-
}
|
|
372
|
-
if ("sandbox" in directives) {
|
|
373
|
-
warnings.push("The sandbox directive is not supported. Use the Content-Security-Policy HTTP header instead.");
|
|
374
|
-
}
|
|
375
|
-
|
|
376
|
-
return {
|
|
377
|
-
ruleId: 'no-meta-csp',
|
|
378
|
-
warnings,
|
|
379
|
-
payload,
|
|
380
|
-
};
|
|
381
|
-
}
|
|
382
|
-
|
|
383
|
-
/**
|
|
384
|
-
* @param {any} element
|
|
385
|
-
* @param {AdapterInterface} adapter
|
|
386
|
-
* @returns {boolean}
|
|
387
|
-
*/
|
|
388
|
-
function isInvalidOriginTrial(element, adapter) {
|
|
389
|
-
if (!isOriginTrial(element, adapter)) {
|
|
390
|
-
return false;
|
|
391
|
-
}
|
|
392
|
-
|
|
393
|
-
const { warnings } = validateOriginTrial(element, adapter);
|
|
394
|
-
return (warnings?.length ?? 0) > 0;
|
|
395
|
-
}
|
|
396
|
-
|
|
397
|
-
/**
|
|
398
|
-
* @param {any} element
|
|
399
|
-
* @param {AdapterInterface} adapter
|
|
400
|
-
* @returns {CustomValidationResult}
|
|
401
|
-
*/
|
|
402
|
-
function validateOriginTrial(element, adapter) {
|
|
403
|
-
/** @type {CustomValidationResult} */
|
|
404
|
-
const metadata = {
|
|
405
|
-
ruleId: 'no-invalid-origin-trial',
|
|
406
|
-
payload: null,
|
|
407
|
-
warnings: [],
|
|
408
|
-
};
|
|
409
|
-
|
|
410
|
-
const token = adapter.getAttribute(element, "content");
|
|
411
|
-
try {
|
|
412
|
-
metadata.payload = decodeOriginTrialToken(token);
|
|
413
|
-
} catch {
|
|
414
|
-
metadata.warnings?.push("Invalid origin trial token: invalid token");
|
|
415
|
-
return metadata;
|
|
416
|
-
}
|
|
417
|
-
|
|
418
|
-
if (metadata.payload.expiry < new Date()) {
|
|
419
|
-
metadata.warnings?.push("Invalid origin trial token: expired");
|
|
420
|
-
}
|
|
421
|
-
|
|
422
|
-
if (typeof document !== 'undefined' && document.location && document.location.href) {
|
|
423
|
-
if (!isSameOrigin(metadata.payload.origin, document.location.href)) {
|
|
424
|
-
const subdomain = isSubdomain(metadata.payload.origin, document.location.href);
|
|
425
|
-
if (subdomain && !metadata.payload.isSubdomain) {
|
|
426
|
-
metadata.warnings?.push("Invalid origin trial token: invalid subdomain");
|
|
427
|
-
} else if (!subdomain && !metadata.payload.isThirdParty) {
|
|
428
|
-
metadata.warnings?.push("Invalid origin trial token: invalid third-party origin");
|
|
429
|
-
}
|
|
430
|
-
}
|
|
431
|
-
}
|
|
432
|
-
|
|
433
|
-
return metadata;
|
|
434
|
-
}
|
|
435
|
-
|
|
436
|
-
/**
|
|
437
|
-
* Decode origin trial token payload
|
|
438
|
-
* @param {string|null} token
|
|
439
|
-
* @returns {any}
|
|
440
|
-
*/
|
|
441
|
-
function decodeOriginTrialToken(token) {
|
|
442
|
-
if (!token) throw new Error("Missing token");
|
|
443
|
-
const buffer = new Uint8Array([...atob(token)].map((a) => a.charCodeAt(0)));
|
|
444
|
-
const view = new DataView(buffer.buffer);
|
|
445
|
-
const length = view.getUint32(65, false);
|
|
446
|
-
const payload = JSON.parse(new TextDecoder().decode(buffer.slice(69, 69 + length)));
|
|
447
|
-
payload.expiry = new Date(payload.expiry * 1000);
|
|
448
|
-
return payload;
|
|
449
|
-
}
|
|
450
|
-
|
|
451
|
-
/**
|
|
452
|
-
* @param {string} a
|
|
453
|
-
* @param {string} b
|
|
454
|
-
* @returns {boolean}
|
|
455
|
-
*/
|
|
456
|
-
function isSameOrigin(a, b) {
|
|
457
|
-
return new URL(a).origin === new URL(b).origin;
|
|
458
|
-
}
|
|
459
|
-
|
|
460
|
-
/**
|
|
461
|
-
* @param {string} a
|
|
462
|
-
* @param {string} b
|
|
463
|
-
* @returns {boolean}
|
|
464
|
-
*/
|
|
465
|
-
function isSubdomain(a, b) {
|
|
466
|
-
const urlA = new URL(a);
|
|
467
|
-
const urlB = new URL(b);
|
|
468
|
-
return urlB.host.endsWith(`.${urlA.host}`);
|
|
469
|
-
}
|
|
470
|
-
|
|
471
|
-
/**
|
|
472
|
-
* @param {any} element
|
|
473
|
-
* @param {AdapterInterface} adapter
|
|
474
|
-
* @returns {boolean}
|
|
475
|
-
*/
|
|
476
|
-
function isDefaultStyle(element, adapter) {
|
|
477
|
-
if (adapter.getTagName(element) !== 'meta') return false;
|
|
478
|
-
const httpEquiv = adapter.getAttribute(element, 'http-equiv');
|
|
479
|
-
return httpEquiv?.toLowerCase() === 'default-style';
|
|
480
|
-
}
|
|
481
|
-
|
|
482
|
-
/**
|
|
483
|
-
* @param {any} element
|
|
484
|
-
* @param {AdapterInterface} adapter
|
|
485
|
-
* @returns {boolean}
|
|
486
|
-
*/
|
|
487
|
-
function isContentType(element, adapter) {
|
|
488
|
-
if (adapter.getTagName(element) !== 'meta') return false;
|
|
489
|
-
if (adapter.hasAttribute(element, 'charset')) return true;
|
|
490
|
-
const httpEquiv = adapter.getAttribute(element, 'http-equiv');
|
|
491
|
-
return httpEquiv?.toLowerCase() === 'content-type';
|
|
492
|
-
}
|
|
493
|
-
|
|
494
|
-
/**
|
|
495
|
-
* @param {any} element
|
|
496
|
-
* @param {AdapterInterface} adapter
|
|
497
|
-
* @returns {boolean}
|
|
498
|
-
*/
|
|
499
|
-
function isHttpEquiv(element, adapter) {
|
|
500
|
-
if (adapter.getTagName(element) !== 'meta') return false;
|
|
501
|
-
return adapter.hasAttribute(element, 'http-equiv');
|
|
502
|
-
}
|
|
503
|
-
|
|
504
|
-
/**
|
|
505
|
-
* @param {any} element
|
|
506
|
-
* @param {AdapterInterface} adapter
|
|
507
|
-
* @returns {boolean}
|
|
508
|
-
*/
|
|
509
|
-
function isMetaViewport(element, adapter) {
|
|
510
|
-
if (adapter.getTagName(element) !== 'meta') return false;
|
|
511
|
-
const name = adapter.getAttribute(element, 'name');
|
|
512
|
-
return name?.toLowerCase() === 'viewport';
|
|
513
|
-
}
|
|
514
|
-
|
|
515
|
-
/**
|
|
516
|
-
* @param {any} element
|
|
517
|
-
* @param {AdapterInterface} adapter
|
|
518
|
-
* @returns {boolean}
|
|
519
|
-
*/
|
|
520
|
-
function isInvalidDefaultStyle(element, adapter) {
|
|
521
|
-
if (!isDefaultStyle(element, adapter)) {
|
|
522
|
-
return false;
|
|
523
|
-
}
|
|
524
|
-
|
|
525
|
-
const { warnings } = validateDefaultStyle(element, adapter);
|
|
526
|
-
return (warnings?.length ?? 0) > 0;
|
|
527
|
-
}
|
|
528
|
-
|
|
529
|
-
/**
|
|
530
|
-
* @param {any} element
|
|
531
|
-
* @param {AdapterInterface} adapter
|
|
532
|
-
* @returns {boolean}
|
|
533
|
-
*/
|
|
534
|
-
function isInvalidContentType(element, adapter) {
|
|
535
|
-
if (!isContentType(element, adapter)) {
|
|
536
|
-
return false;
|
|
537
|
-
}
|
|
538
|
-
|
|
539
|
-
const { warnings } = validateContentType(element, adapter);
|
|
540
|
-
return (warnings?.length ?? 0) > 0;
|
|
541
|
-
}
|
|
542
|
-
|
|
543
|
-
/**
|
|
544
|
-
* @param {any} element
|
|
545
|
-
* @param {AdapterInterface} adapter
|
|
546
|
-
* @returns {boolean}
|
|
547
|
-
*/
|
|
548
|
-
function isInvalidHttpEquiv(element, adapter) {
|
|
549
|
-
if (!isHttpEquiv(element, adapter)) {
|
|
550
|
-
return false;
|
|
551
|
-
}
|
|
552
|
-
|
|
553
|
-
const { warnings } = validateHttpEquiv(element, adapter);
|
|
554
|
-
return (warnings?.length ?? 0) > 0;
|
|
555
|
-
}
|
|
556
|
-
|
|
557
|
-
/**
|
|
558
|
-
* @param {any} element
|
|
559
|
-
* @param {AdapterInterface} adapter
|
|
560
|
-
* @returns {boolean}
|
|
561
|
-
*/
|
|
562
|
-
function isInvalidMetaViewport(element, adapter) {
|
|
563
|
-
if (!isMetaViewport(element, adapter)) {
|
|
564
|
-
return false;
|
|
565
|
-
}
|
|
566
|
-
|
|
567
|
-
const { warnings } = validateMetaViewport(element, adapter);
|
|
568
|
-
return (warnings?.length ?? 0) > 0;
|
|
569
|
-
}
|
|
570
|
-
|
|
571
|
-
/**
|
|
572
|
-
* @param {any} element
|
|
573
|
-
* @param {AdapterInterface} adapter
|
|
574
|
-
* @param {any} [parentElement=null]
|
|
575
|
-
* @returns {boolean}
|
|
576
|
-
*/
|
|
577
|
-
function isUnnecessaryPreload(element, adapter, parentElement = null) {
|
|
578
|
-
const tagName = adapter.getTagName(element);
|
|
579
|
-
if (tagName !== 'link') {
|
|
580
|
-
return false;
|
|
581
|
-
}
|
|
582
|
-
const rel = adapter.getAttribute(element, 'rel');
|
|
583
|
-
const relLower = rel?.toLowerCase();
|
|
584
|
-
if (relLower !== 'preload' && relLower !== 'modulepreload') {
|
|
585
|
-
return false;
|
|
586
|
-
}
|
|
587
|
-
const href = adapter.getAttribute(element, "href");
|
|
588
|
-
if (!href) {
|
|
589
|
-
return false;
|
|
590
|
-
}
|
|
591
|
-
const parent = parentElement || adapter.getParent(element);
|
|
592
|
-
if (!parent) {
|
|
593
|
-
return false;
|
|
594
|
-
}
|
|
595
|
-
const found = findElementWithSource(parent, href, element, adapter);
|
|
596
|
-
return found != null;
|
|
597
|
-
}
|
|
598
|
-
|
|
599
|
-
/**
|
|
600
|
-
* @param {any} element
|
|
601
|
-
* @param {AdapterInterface} adapter
|
|
602
|
-
* @returns {boolean}
|
|
603
|
-
*/
|
|
604
|
-
function isInvalidFontPreload(element, adapter) {
|
|
605
|
-
const tagName = adapter.getTagName(element);
|
|
606
|
-
if (tagName !== 'link') {
|
|
607
|
-
return false;
|
|
608
|
-
}
|
|
609
|
-
const rel = adapter.getAttribute(element, 'rel');
|
|
610
|
-
if (rel?.toLowerCase() !== 'preload') {
|
|
611
|
-
return false;
|
|
612
|
-
}
|
|
613
|
-
const as = adapter.getAttribute(element, 'as');
|
|
614
|
-
if (as?.toLowerCase() !== 'font') {
|
|
615
|
-
return false;
|
|
616
|
-
}
|
|
617
|
-
return !adapter.hasAttribute(element, 'crossorigin');
|
|
618
|
-
}
|
|
619
|
-
|
|
620
|
-
/**
|
|
621
|
-
* @param {any} element
|
|
622
|
-
* @param {AdapterInterface} adapter
|
|
623
|
-
* @returns {CustomValidationResult}
|
|
624
|
-
*/
|
|
625
|
-
function validateInvalidFontPreload(element, adapter) {
|
|
626
|
-
const warnings = ["Font preloads must have the crossorigin attribute set, even for same-origin fonts."];
|
|
627
|
-
return {
|
|
628
|
-
ruleId: 'valid-font-preload',
|
|
629
|
-
warnings,
|
|
630
|
-
payload: null
|
|
631
|
-
};
|
|
632
|
-
}
|
|
633
|
-
|
|
634
|
-
/**
|
|
635
|
-
* Find an element with matching source using adapter
|
|
636
|
-
* @param {any} parent - Parent element to search within
|
|
637
|
-
* @param {string} sourceUrl - URL to match
|
|
638
|
-
* @param {any} excludeElement - Element to exclude from search
|
|
639
|
-
* @param {AdapterInterface} adapter - Adapter instance
|
|
640
|
-
* @returns {any|null} - Matching element or null
|
|
641
|
-
*/
|
|
642
|
-
function findElementWithSource(parent, sourceUrl, excludeElement, adapter) {
|
|
643
|
-
const children = adapter.getChildren(parent);
|
|
644
|
-
|
|
645
|
-
for (const child of children) {
|
|
646
|
-
if (child === excludeElement) {
|
|
647
|
-
continue;
|
|
648
|
-
}
|
|
649
|
-
|
|
650
|
-
const tagName = adapter.getTagName(child);
|
|
651
|
-
|
|
652
|
-
if (tagName === 'link') {
|
|
653
|
-
const rel = adapter.getAttribute(child, 'rel');
|
|
654
|
-
if (rel && /\b(preload|modulepreload)\b/i.test(rel)) {
|
|
655
|
-
continue;
|
|
656
|
-
}
|
|
657
|
-
|
|
658
|
-
const childHref = adapter.getAttribute(child, 'href');
|
|
659
|
-
if (childHref === sourceUrl) {
|
|
660
|
-
return child;
|
|
661
|
-
}
|
|
662
|
-
}
|
|
663
|
-
|
|
664
|
-
if (tagName === 'script') {
|
|
665
|
-
const src = adapter.getAttribute(child, 'src');
|
|
666
|
-
if (src === sourceUrl) {
|
|
667
|
-
return child;
|
|
668
|
-
}
|
|
669
|
-
}
|
|
670
|
-
}
|
|
671
|
-
|
|
672
|
-
return null;
|
|
673
|
-
}
|
|
674
|
-
|
|
675
|
-
/**
|
|
676
|
-
* @param {any} element
|
|
677
|
-
* @param {AdapterInterface} adapter
|
|
678
|
-
* @returns {CustomValidationResult}
|
|
679
|
-
*/
|
|
680
|
-
function validateDefaultStyle(element, adapter) {
|
|
681
|
-
/** @type {string[]} */
|
|
682
|
-
const warnings = [];
|
|
683
|
-
/** @type {any} */
|
|
684
|
-
let payload = null;
|
|
685
|
-
|
|
686
|
-
const title = adapter.getAttribute(element, "content");
|
|
687
|
-
|
|
688
|
-
if (element.parentElement && element.parentElement.querySelector) {
|
|
689
|
-
const stylesheet = element.parentElement.querySelector(
|
|
690
|
-
`link[rel~="alternate" i][rel~="stylesheet" i][title="${title}"]`
|
|
691
|
-
);
|
|
692
|
-
|
|
693
|
-
if (!title) {
|
|
694
|
-
warnings.push("This has no effect. The content attribute must be set to a valid stylesheet title.");
|
|
695
|
-
} else if (!stylesheet) {
|
|
696
|
-
payload = {
|
|
697
|
-
alternateStylesheets: Array.from(
|
|
698
|
-
element.parentElement.querySelectorAll('link[rel~="alternate" i][rel~="stylesheet" i]')
|
|
699
|
-
),
|
|
700
|
-
};
|
|
701
|
-
warnings.push(`This has no effect. No alternate stylesheet found having title="${title}".`);
|
|
702
|
-
}
|
|
703
|
-
} else if (!title) {
|
|
704
|
-
warnings.push("This has no effect. The content attribute must be set to a valid stylesheet title.");
|
|
705
|
-
}
|
|
706
|
-
|
|
707
|
-
warnings.push(
|
|
708
|
-
"Even when used correctly, the default-style method of setting a preferred stylesheet results in a flash of unstyled content. Use modern CSS features like @media rules instead."
|
|
709
|
-
);
|
|
710
|
-
|
|
711
|
-
return { ruleId: 'no-default-style', warnings, payload };
|
|
712
|
-
}
|
|
713
|
-
|
|
714
|
-
/**
|
|
715
|
-
* @param {any} element
|
|
716
|
-
* @param {AdapterInterface} adapter
|
|
717
|
-
* @returns {CustomValidationResult}
|
|
718
|
-
*/
|
|
719
|
-
function validateContentType(element, adapter) {
|
|
720
|
-
/** @type {string[]} */
|
|
721
|
-
const warnings = [];
|
|
722
|
-
/** @type {any} */
|
|
723
|
-
let payload = null;
|
|
724
|
-
|
|
725
|
-
const isCharset = adapter.hasAttribute(element, 'charset');
|
|
726
|
-
const httpEquiv = adapter.getAttribute(element, 'http-equiv');
|
|
727
|
-
const isContentTypeMeta = httpEquiv?.toLowerCase() === 'content-type';
|
|
728
|
-
|
|
729
|
-
if (isCharset || isContentTypeMeta) {
|
|
730
|
-
const siblings = adapter.getSiblings(element);
|
|
731
|
-
const hasDuplicateCharset = siblings.some(sibling => {
|
|
732
|
-
if (adapter.getTagName(sibling) !== 'meta') return false;
|
|
733
|
-
if (adapter.hasAttribute(sibling, 'charset')) return true;
|
|
734
|
-
const siblingHttpEquiv = adapter.getAttribute(sibling, 'http-equiv');
|
|
735
|
-
return siblingHttpEquiv?.toLowerCase() === 'content-type';
|
|
736
|
-
});
|
|
737
|
-
|
|
738
|
-
if (hasDuplicateCharset) {
|
|
739
|
-
const parent = adapter.getParent(element);
|
|
740
|
-
if (parent) {
|
|
741
|
-
const charsetElements = adapter.getChildren(parent).filter((/** @type {any} */ child) => {
|
|
742
|
-
if (adapter.getTagName(child) !== 'meta') return false;
|
|
743
|
-
if (adapter.hasAttribute(child, 'charset')) return true;
|
|
744
|
-
const childHttpEquiv = adapter.getAttribute(child, 'http-equiv');
|
|
745
|
-
return childHttpEquiv?.toLowerCase() === 'content-type';
|
|
746
|
-
});
|
|
747
|
-
const encodingDeclaration = charsetElements.find((/** @type {any} */ el) => el !== element);
|
|
748
|
-
if (encodingDeclaration) {
|
|
749
|
-
payload = payload ?? {};
|
|
750
|
-
payload.encodingDeclaration = encodingDeclaration;
|
|
751
|
-
warnings.push(
|
|
752
|
-
`There can only be one meta-based character encoding declaration per document. Already found \`${adapter.stringify(encodingDeclaration)}\`.`
|
|
753
|
-
);
|
|
754
|
-
}
|
|
755
|
-
}
|
|
756
|
-
}
|
|
757
|
-
}
|
|
758
|
-
|
|
759
|
-
if (element.ownerDocument?.documentElement?.outerHTML && element.outerHTML) {
|
|
760
|
-
const charPos = element.ownerDocument.documentElement.outerHTML.indexOf(element.outerHTML) + element.outerHTML.length;
|
|
761
|
-
if (charPos > 1024) {
|
|
762
|
-
payload = payload ?? {};
|
|
763
|
-
payload.characterPosition = charPos;
|
|
764
|
-
warnings.push(
|
|
765
|
-
`The element containing the character encoding declaration must be serialized completely within the first 1024 bytes of the document. Found at byte ${charPos}.`
|
|
766
|
-
);
|
|
767
|
-
}
|
|
768
|
-
}
|
|
769
|
-
|
|
770
|
-
let charset = null;
|
|
771
|
-
if (isCharset) {
|
|
772
|
-
charset = adapter.getAttribute(element, "charset");
|
|
773
|
-
} else {
|
|
774
|
-
const charsetPattern = /text\/html;\s*charset=(.*)/i;
|
|
775
|
-
charset = adapter.getAttribute(element, "content")?.match(charsetPattern)?.[1]?.trim();
|
|
776
|
-
}
|
|
777
|
-
|
|
778
|
-
if (charset?.toLowerCase() != "utf-8") {
|
|
779
|
-
payload = payload ?? {};
|
|
780
|
-
payload.charset = charset;
|
|
781
|
-
warnings.push(`Documents are required to use UTF-8 encoding. Found "${charset}".`);
|
|
782
|
-
}
|
|
783
|
-
|
|
784
|
-
if (warnings.length) {
|
|
785
|
-
warnings[warnings.length - 1] +=
|
|
786
|
-
"\nLearn more: https://html.spec.whatwg.org/multipage/semantics.html#character-encoding-declaration";
|
|
787
|
-
}
|
|
788
|
-
|
|
789
|
-
return { ruleId: 'valid-charset', warnings, payload };
|
|
790
|
-
}
|
|
791
|
-
|
|
792
|
-
/**
|
|
793
|
-
* @param {any} element
|
|
794
|
-
* @param {AdapterInterface} adapter
|
|
795
|
-
* @returns {CustomValidationResult}
|
|
796
|
-
*/
|
|
797
|
-
function validateHttpEquiv(element, adapter) {
|
|
798
|
-
/** @type {string[]} */
|
|
799
|
-
const warnings = [];
|
|
800
|
-
const type = adapter.getAttribute(element, "http-equiv")?.toLowerCase() || '';
|
|
801
|
-
const content = adapter.getAttribute(element, "content")?.toLowerCase();
|
|
802
|
-
|
|
803
|
-
switch (type) {
|
|
804
|
-
case "content-security-policy":
|
|
805
|
-
case "content-security-policy-report-only":
|
|
806
|
-
case "origin-trial":
|
|
807
|
-
case "content-type":
|
|
808
|
-
case "default-style":
|
|
809
|
-
break;
|
|
810
|
-
|
|
811
|
-
case "refresh":
|
|
812
|
-
if (!content) {
|
|
813
|
-
warnings.push(
|
|
814
|
-
"This doesn't do anything. The content attribute must be set. However, using refresh is discouraged."
|
|
815
|
-
);
|
|
816
|
-
break;
|
|
817
|
-
}
|
|
818
|
-
if (content.includes("url=")) {
|
|
819
|
-
warnings.push("Meta auto-redirects are discouraged. Use HTTP 3XX responses instead.");
|
|
820
|
-
} else {
|
|
821
|
-
warnings.push("Meta auto-refreshes are discouraged unless users have the ability to disable it.");
|
|
822
|
-
}
|
|
823
|
-
break;
|
|
824
|
-
|
|
825
|
-
case "x-dns-prefetch-control":
|
|
826
|
-
if (content == "on") {
|
|
827
|
-
warnings.push(`DNS prefetching is enabled by default. Setting it to "${content}" has no effect.`);
|
|
828
|
-
} else if (content != "off") {
|
|
829
|
-
warnings.push(
|
|
830
|
-
`This is a non-standard way of disabling DNS prefetching, which is a performance optimization. Found content="${content}". Use content="off" if you have a legitimate security concern, otherwise remove it.`
|
|
831
|
-
);
|
|
832
|
-
} else {
|
|
833
|
-
warnings.push(
|
|
834
|
-
"This is non-standard, however most browsers support disabling speculative DNS prefetching. It should still be noted that DNS prefetching is a generally accepted performance optimization and you should only disable it if you have specific security concerns."
|
|
835
|
-
);
|
|
836
|
-
}
|
|
837
|
-
break;
|
|
838
|
-
|
|
839
|
-
case "cache-control":
|
|
840
|
-
case "etag":
|
|
841
|
-
case "pragma":
|
|
842
|
-
case "expires":
|
|
843
|
-
case "last-modified":
|
|
844
|
-
warnings.push("This doesn't do anything. Use HTTP headers for any cache directives.");
|
|
845
|
-
break;
|
|
846
|
-
|
|
847
|
-
case "x-frame-options":
|
|
848
|
-
warnings.push("This doesn't do anything. Use the CSP HTTP header with the frame-ancestors directive instead.");
|
|
849
|
-
break;
|
|
850
|
-
|
|
851
|
-
case "x-ua-compatible":
|
|
852
|
-
case "content-style-type":
|
|
853
|
-
case "content-script-type":
|
|
854
|
-
case "imagetoolbar":
|
|
855
|
-
case "cleartype":
|
|
856
|
-
case "page-enter":
|
|
857
|
-
case "page-exit":
|
|
858
|
-
case "site-enter":
|
|
859
|
-
case "site-exit":
|
|
860
|
-
case "msthemecompatible":
|
|
861
|
-
case "window-target":
|
|
862
|
-
warnings.push("This doesn't do anything. It was an Internet Explorer feature and is now deprecated.");
|
|
863
|
-
break;
|
|
864
|
-
|
|
865
|
-
case "content-language":
|
|
866
|
-
case "language":
|
|
867
|
-
warnings.push("This is non-conforming. Use the html[lang] attribute instead.");
|
|
868
|
-
break;
|
|
869
|
-
|
|
870
|
-
case "set-cookie":
|
|
871
|
-
warnings.push("This is non-conforming. Use the Set-Cookie HTTP header instead.");
|
|
872
|
-
break;
|
|
873
|
-
|
|
874
|
-
case "application-name":
|
|
875
|
-
case "author":
|
|
876
|
-
case "description":
|
|
877
|
-
case "generator":
|
|
878
|
-
case "keywords":
|
|
879
|
-
case "referrer":
|
|
880
|
-
case "theme-color":
|
|
881
|
-
case "color-scheme":
|
|
882
|
-
case "viewport":
|
|
883
|
-
case "creator":
|
|
884
|
-
case "googlebot":
|
|
885
|
-
case "publisher":
|
|
886
|
-
case "robots":
|
|
887
|
-
warnings.push(`This doesn't do anything. Did you mean \`meta[name=${type}]\`?`);
|
|
888
|
-
break;
|
|
889
|
-
|
|
890
|
-
case "encoding":
|
|
891
|
-
warnings.push("This doesn't do anything. Did you mean `meta[charset]`?");
|
|
892
|
-
break;
|
|
893
|
-
|
|
894
|
-
case "title":
|
|
895
|
-
warnings.push("This doesn't do anything. Did you mean to use the `title` tag instead?");
|
|
896
|
-
break;
|
|
897
|
-
|
|
898
|
-
case "accept-ch":
|
|
899
|
-
case "delegate-ch":
|
|
900
|
-
warnings.push("This is non-standard and may not work across browsers. Use HTTP headers instead.");
|
|
901
|
-
break;
|
|
902
|
-
|
|
903
|
-
default:
|
|
904
|
-
warnings.push(
|
|
905
|
-
"This is non-standard and may not work across browsers. http-equiv is not an alternative to HTTP headers."
|
|
906
|
-
);
|
|
907
|
-
break;
|
|
908
|
-
}
|
|
909
|
-
|
|
910
|
-
return {
|
|
911
|
-
ruleId: 'no-invalid-http-equiv',
|
|
912
|
-
warnings,
|
|
913
|
-
};
|
|
914
|
-
}
|
|
915
|
-
|
|
916
|
-
/**
|
|
917
|
-
* @param {any} element
|
|
918
|
-
* @param {AdapterInterface} adapter
|
|
919
|
-
* @returns {CustomValidationResult}
|
|
920
|
-
*/
|
|
921
|
-
function validateMetaViewport(element, adapter) {
|
|
922
|
-
/** @type {string[]} */
|
|
923
|
-
const warnings = [];
|
|
924
|
-
/** @type {any} */
|
|
925
|
-
let payload = null;
|
|
926
|
-
|
|
927
|
-
const siblings = adapter.getSiblings(element);
|
|
928
|
-
const hasDuplicateViewport = siblings.some(sibling => {
|
|
929
|
-
if (adapter.getTagName(sibling) !== 'meta') return false;
|
|
930
|
-
const name = adapter.getAttribute(sibling, 'name');
|
|
931
|
-
return name?.toLowerCase() === 'viewport';
|
|
932
|
-
});
|
|
933
|
-
|
|
934
|
-
if (hasDuplicateViewport) {
|
|
935
|
-
const parent = adapter.getParent(element);
|
|
936
|
-
if (parent) {
|
|
937
|
-
const viewportElements = adapter.getChildren(parent).filter((/** @type {any} */ child) => {
|
|
938
|
-
if (adapter.getTagName(child) !== 'meta') return false;
|
|
939
|
-
const name = adapter.getAttribute(child, 'name');
|
|
940
|
-
return name?.toLowerCase() === 'viewport';
|
|
941
|
-
});
|
|
942
|
-
const firstMetaViewport = viewportElements.find((/** @type {any} */ el) => el !== element);
|
|
943
|
-
if (firstMetaViewport) {
|
|
944
|
-
payload = { firstMetaViewport };
|
|
945
|
-
warnings.push(
|
|
946
|
-
"Another meta viewport element has already been declared. Having multiple viewport settings can lead to unexpected behavior."
|
|
947
|
-
);
|
|
948
|
-
return { warnings, payload };
|
|
949
|
-
}
|
|
950
|
-
}
|
|
951
|
-
}
|
|
952
|
-
|
|
953
|
-
const content = adapter.getAttribute(element, "content")?.toLowerCase();
|
|
954
|
-
if (!content) {
|
|
955
|
-
warnings.push("Invalid viewport. The content attribute must be set.");
|
|
956
|
-
return { warnings, payload };
|
|
957
|
-
}
|
|
958
|
-
|
|
959
|
-
/** @type {Record<string, string>} */
|
|
960
|
-
const directives = Object.fromEntries(
|
|
961
|
-
content.split(",").map((directive) => {
|
|
962
|
-
const [key, value] = directive.split("=");
|
|
963
|
-
return [key?.trim(), value?.trim()];
|
|
964
|
-
})
|
|
965
|
-
);
|
|
966
|
-
|
|
967
|
-
if ("width" in directives) {
|
|
968
|
-
const width = directives["width"];
|
|
969
|
-
if (Number(width) < 1 || Number(width) > 10000) {
|
|
970
|
-
warnings.push(`Invalid width "${width}". Numeric values must be between 1 and 10000.`);
|
|
971
|
-
} else if (width != "device-width") {
|
|
972
|
-
warnings.push(`Invalid width "${width}".`);
|
|
973
|
-
}
|
|
974
|
-
}
|
|
975
|
-
|
|
976
|
-
if ("height" in directives) {
|
|
977
|
-
const height = directives["height"];
|
|
978
|
-
if (Number(height) < 1 || Number(height) > 10000) {
|
|
979
|
-
warnings.push(`Invalid height "${height}". Numeric values must be between 1 and 10000.`);
|
|
980
|
-
} else if (height != "device-height") {
|
|
981
|
-
warnings.push(`Invalid height "${height}".`);
|
|
982
|
-
}
|
|
983
|
-
}
|
|
984
|
-
|
|
985
|
-
if ("initial-scale" in directives) {
|
|
986
|
-
const initialScale = Number(directives["initial-scale"]);
|
|
987
|
-
if (isNaN(initialScale)) {
|
|
988
|
-
warnings.push(`Invalid initial zoom level "${directives["initial-scale"]}". Values must be numeric.`);
|
|
989
|
-
}
|
|
990
|
-
if (initialScale < 0.1 || initialScale > 10) {
|
|
991
|
-
warnings.push(`Invalid initial zoom level "${initialScale}". Values must be between 0.1 and 10.`);
|
|
992
|
-
}
|
|
993
|
-
}
|
|
994
|
-
|
|
995
|
-
if ("minimum-scale" in directives) {
|
|
996
|
-
const minimumScale = Number(directives["minimum-scale"]);
|
|
997
|
-
if (isNaN(minimumScale)) {
|
|
998
|
-
warnings.push(`Invalid minimum zoom level "${directives["minimum-scale"]}". Values must be numeric.`);
|
|
999
|
-
}
|
|
1000
|
-
if (minimumScale < 0.1 || minimumScale > 10) {
|
|
1001
|
-
warnings.push(`Invalid minimum zoom level "${minimumScale}". Values must be between 0.1 and 10.`);
|
|
1002
|
-
}
|
|
1003
|
-
}
|
|
1004
|
-
|
|
1005
|
-
if ("maximum-scale" in directives) {
|
|
1006
|
-
const maxScale = Number(directives["maximum-scale"]);
|
|
1007
|
-
if (isNaN(maxScale)) {
|
|
1008
|
-
warnings.push(`Invalid maximum zoom level "${directives["maximum-scale"]}". Values must be numeric.`);
|
|
1009
|
-
}
|
|
1010
|
-
if (maxScale < 0.1 || maxScale > 10) {
|
|
1011
|
-
warnings.push(`Invalid maximum zoom level "${maxScale}". Values must be between 0.1 and 10.`);
|
|
1012
|
-
}
|
|
1013
|
-
if (maxScale < 2) {
|
|
1014
|
-
warnings.push(
|
|
1015
|
-
`Disabling zoom levels under 2x can cause accessibility issues. Found "maximum-scale=${directives["maximum-scale"]}".`
|
|
1016
|
-
);
|
|
1017
|
-
}
|
|
1018
|
-
}
|
|
1019
|
-
|
|
1020
|
-
if ("user-scalable" in directives) {
|
|
1021
|
-
const userScalable = directives["user-scalable"];
|
|
1022
|
-
if (userScalable == "no" || userScalable == "0") {
|
|
1023
|
-
warnings.push(
|
|
1024
|
-
`Disabling zooming can cause accessibility issues to users with visual impairments. Found "user-scalable=${userScalable}".`
|
|
1025
|
-
);
|
|
1026
|
-
}
|
|
1027
|
-
if (!["0", "1", "yes", "no"].includes(userScalable)) {
|
|
1028
|
-
warnings.push(`Unsupported value "${userScalable}" found.`);
|
|
1029
|
-
}
|
|
1030
|
-
}
|
|
1031
|
-
|
|
1032
|
-
if ("interactive-widget" in directives) {
|
|
1033
|
-
const interactiveWidget = directives["interactive-widget"];
|
|
1034
|
-
const validValues = ["resizes-visual", "resizes-content", "overlays-content"];
|
|
1035
|
-
if (!validValues.includes(interactiveWidget)) {
|
|
1036
|
-
warnings.push(`Unsupported value "${interactiveWidget}" found.`);
|
|
1037
|
-
}
|
|
1038
|
-
}
|
|
1039
|
-
|
|
1040
|
-
if ("viewport-fit" in directives) {
|
|
1041
|
-
const viewportFit = directives["viewport-fit"];
|
|
1042
|
-
const validValues = ["auto", "contain", "cover"];
|
|
1043
|
-
if (!validValues.includes(viewportFit)) {
|
|
1044
|
-
warnings.push(`Unsupported value "${viewportFit}" found. Should be one of: ${validValues.join(", ")}.`);
|
|
1045
|
-
}
|
|
1046
|
-
}
|
|
1047
|
-
|
|
1048
|
-
if ("shrink-to-fit" in directives) {
|
|
1049
|
-
warnings.push(
|
|
1050
|
-
"The shrink-to-fit directive has been obsolete since iOS 9.2.\n See https://www.scottohara.me/blog/2018/12/11/shrink-to-fit.html"
|
|
1051
|
-
);
|
|
1052
|
-
}
|
|
1053
|
-
|
|
1054
|
-
const validDirectives = new Set([
|
|
1055
|
-
"width",
|
|
1056
|
-
"height",
|
|
1057
|
-
"initial-scale",
|
|
1058
|
-
"minimum-scale",
|
|
1059
|
-
"maximum-scale",
|
|
1060
|
-
"user-scalable",
|
|
1061
|
-
"interactive-widget",
|
|
1062
|
-
]);
|
|
1063
|
-
|
|
1064
|
-
Object.keys(directives)
|
|
1065
|
-
.filter((directive) => {
|
|
1066
|
-
if (validDirectives.has(directive)) {
|
|
1067
|
-
return false;
|
|
1068
|
-
}
|
|
1069
|
-
if (directive == "shrink-to-fit") {
|
|
1070
|
-
return false;
|
|
1071
|
-
}
|
|
1072
|
-
if (directive == "viewport-fit") {
|
|
1073
|
-
return false;
|
|
1074
|
-
}
|
|
1075
|
-
return true;
|
|
1076
|
-
})
|
|
1077
|
-
.forEach((directive) => {
|
|
1078
|
-
warnings.push(`Invalid viewport directive "${directive}".`);
|
|
1079
|
-
});
|
|
1080
|
-
|
|
1081
|
-
return { ruleId: 'valid-meta-viewport', warnings, payload };
|
|
1082
|
-
}
|
|
1083
|
-
|
|
1084
|
-
/**
|
|
1085
|
-
* @param {any} element
|
|
1086
|
-
* @param {AdapterInterface} adapter
|
|
1087
|
-
* @param {any} [parentElement=null]
|
|
1088
|
-
* @returns {CustomValidationResult}
|
|
1089
|
-
*/
|
|
1090
|
-
function validateUnnecessaryPreload(element, adapter, parentElement = null) {
|
|
1091
|
-
const href = adapter.getAttribute(element, "href");
|
|
1092
|
-
if (!href) {
|
|
1093
|
-
return { ruleId: 'no-unnecessary-preload', warnings: [] };
|
|
1094
|
-
}
|
|
1095
|
-
const parent = parentElement || adapter.getParent(element);
|
|
1096
|
-
if (!parent) {
|
|
1097
|
-
return { ruleId: 'no-unnecessary-preload', warnings: [] };
|
|
1098
|
-
}
|
|
1099
|
-
const preloadedElement = findElementWithSource(parent, href, element, adapter);
|
|
1100
|
-
if (!preloadedElement) {
|
|
1101
|
-
return { ruleId: 'no-unnecessary-preload', warnings: [] };
|
|
1102
|
-
}
|
|
1103
|
-
return {
|
|
1104
|
-
ruleId: 'no-unnecessary-preload',
|
|
1105
|
-
warnings: [
|
|
1106
|
-
`This preload has little to no effect. ${href} is already discoverable by another ${adapter.getTagName(preloadedElement)} element.`,
|
|
1107
|
-
],
|
|
1108
|
-
};
|
|
1109
|
-
}
|