@shayanthenerd/eslint-config 0.2.0 → 0.4.1

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.
Files changed (66) hide show
  1. package/README.md +1 -1
  2. package/dist/prettier.config.d.ts +6 -0
  3. package/dist/prettier.config.js +22 -26
  4. package/package.json +9 -12
  5. package/dist/_virtual/rolldown_runtime.cjs +0 -30
  6. package/dist/configs/base.cjs +0 -44
  7. package/dist/configs/commons.cjs +0 -27
  8. package/dist/configs/css.cjs +0 -29
  9. package/dist/configs/cypress.cjs +0 -23
  10. package/dist/configs/html.cjs +0 -23
  11. package/dist/configs/importX.cjs +0 -46
  12. package/dist/configs/nuxtMultiRootTemplate.cjs +0 -14
  13. package/dist/configs/oxlintOverrides.cjs +0 -51
  14. package/dist/configs/perfectionist.cjs +0 -24
  15. package/dist/configs/playwright.cjs +0 -23
  16. package/dist/configs/storybook.cjs +0 -24
  17. package/dist/configs/stylistic.cjs +0 -23
  18. package/dist/configs/tailwind.cjs +0 -43
  19. package/dist/configs/typescript.cjs +0 -31
  20. package/dist/configs/vitest.cjs +0 -23
  21. package/dist/configs/vue.cjs +0 -35
  22. package/dist/configs/vueComponentNames.cjs +0 -19
  23. package/dist/index.cjs +0 -55
  24. package/dist/index.d.cts +0 -16
  25. package/dist/rules/css.cjs +0 -65
  26. package/dist/rules/cypress.cjs +0 -16
  27. package/dist/rules/html.cjs +0 -53
  28. package/dist/rules/importX.cjs +0 -51
  29. package/dist/rules/javascript.cjs +0 -164
  30. package/dist/rules/perfectionist.cjs +0 -73
  31. package/dist/rules/playwright.cjs +0 -28
  32. package/dist/rules/storybook.cjs +0 -16
  33. package/dist/rules/stylistic.cjs +0 -160
  34. package/dist/rules/tailwind.cjs +0 -36
  35. package/dist/rules/typescript.cjs +0 -62
  36. package/dist/rules/vitest.cjs +0 -47
  37. package/dist/rules/vue.cjs +0 -171
  38. package/dist/rules/vueAccessibility.cjs +0 -23
  39. package/dist/types/configOptions/base.d.cts +0 -47
  40. package/dist/types/configOptions/css.d.cts +0 -27
  41. package/dist/types/configOptions/html.d.cts +0 -27
  42. package/dist/types/configOptions/importX.d.cts +0 -29
  43. package/dist/types/configOptions/nuxt.d.cts +0 -42
  44. package/dist/types/configOptions/perfectionist.d.cts +0 -16
  45. package/dist/types/configOptions/stylistic.d.cts +0 -145
  46. package/dist/types/configOptions/tailwind.d.cts +0 -46
  47. package/dist/types/configOptions/test.d.cts +0 -55
  48. package/dist/types/configOptions/typescript.d.cts +0 -36
  49. package/dist/types/configOptions/vue.d.cts +0 -211
  50. package/dist/types/configOptions/vueAccessibility.d.cts +0 -34
  51. package/dist/types/eslint-schema.d.cts +0 -13732
  52. package/dist/types/eslintRules.d.cts +0 -12
  53. package/dist/types/helpers.d.cts +0 -5
  54. package/dist/types/index.d.cts +0 -360
  55. package/dist/utils/globs.cjs +0 -32
  56. package/dist/utils/ignores/defaultIgnorePatterns.cjs +0 -58
  57. package/dist/utils/ignores/getIgnorePatterns.cjs +0 -16
  58. package/dist/utils/ignores/resolveGitignorePatterns.cjs +0 -27
  59. package/dist/utils/isEmptyString.cjs +0 -8
  60. package/dist/utils/isEnabled.cjs +0 -8
  61. package/dist/utils/isPackageDetected.cjs +0 -22
  62. package/dist/utils/options/defaultOptions.cjs +0 -169
  63. package/dist/utils/options/enableDetectedConfigs.cjs +0 -40
  64. package/dist/utils/options/mergeWithDefaults.cjs +0 -22
  65. package/dist/utils/vue/getRestrictedVueElements.cjs +0 -28
  66. package/dist/utils/vue/getRestrictedVueInputs.cjs +0 -24
@@ -1,42 +0,0 @@
1
- //#region src/types/configOptions/nuxt.d.ts
2
- interface NuxtOptions {
3
- /**
4
- * Whether [NuxtImage](https://image.nuxt.com) is used in the project.
5
- *
6
- * Enforce the use of `<NuxtImg>` instead of `<img>`, and `<NuxtPicture>` instead of `<picture>`.
7
- *
8
- * @default false // `true` if "@nuxt/image" is detected in the package.json file when `autoDetectDeps` is enabled
9
- *
10
- * @see [vue/no-restricted-html-elements](https://eslint.vuejs.org/rules/no-restricted-html-elements)
11
- */
12
- image?: boolean;
13
-
14
- /**
15
- * Whether [NuxtUI](https://ui.nuxt.com) is used in the project.
16
- *
17
- * Enforce the use of NuxtUI components over their standard counterparts. For example, `<ULink>` must be used instead of `<a>`, `<UInput>` instead of `<input>`, etc.
18
- *
19
- * @default false // `true` if "@nuxt/ui" is detected in the package.json file when `autoDetectDeps` is enabled
20
- *
21
- * @see [vue/no-restricted-html-elements](https://eslint.vuejs.org/rules/no-restricted-html-elements)
22
- */
23
- ui?: boolean | {
24
- /**
25
- * The prefix of the components.
26
- *
27
- * This is used by
28
- * [vue/no-restricted-html-elements](https://eslint.vuejs.org/rules/no-restricted-html-elements) and
29
- * [vue/no-restricted-static-attribute](https://eslint.vuejs.org/rules/no-restricted-static-attribute)
30
- * to suggest the alternative components with the correct prefix.
31
- *
32
- * It will fall back to the default value if set to an empty string (`''`).
33
- *
34
- * @default 'U'
35
- *
36
- * @see [NuxtUI Options: Prefix](https://ui.nuxt.com/getting-started/installation/nuxt#prefix)
37
- */
38
- prefix?: string;
39
- };
40
- }
41
- //#endregion
42
- export { type NuxtOptions };
@@ -1,16 +0,0 @@
1
- import { RuleOptions } from "../eslintRules.cjs";
2
- import { ConfigWithOverrides } from "../index.cjs";
3
-
4
- //#region src/types/configOptions/perfectionist.d.ts
5
- interface PerfectionistOptions extends ConfigWithOverrides {
6
- /**
7
- * The type of sorting.
8
- *
9
- * @default 'line-length'
10
- *
11
- * @see [Perfectionist Settings: `type` option](https://perfectionist.dev/guide/getting-started#settings)
12
- */
13
- sortType?: RuleOptions<'perfectionist/sort-imports'>['type'];
14
- }
15
- //#endregion
16
- export { type PerfectionistOptions };
@@ -1,145 +0,0 @@
1
- import { RuleOptions } from "../eslintRules.cjs";
2
- import { ConfigWithOverrides } from "../index.cjs";
3
-
4
- //#region src/types/configOptions/stylistic.d.ts
5
- interface StylisticOptions extends ConfigWithOverrides {
6
- /**
7
- * Add semicolons at the end of statements.
8
- *
9
- * @default 'always'
10
- *
11
- * @see [@stylistic/semi](https://eslint.style/rules/semi)
12
- */
13
- semi?: RuleOptions<'@stylistic/semi'>;
14
-
15
- /**
16
- * Add trailing commas to object and array literals.
17
- *
18
- * This is also used by
19
- * [@stylistic/member-delimiter-style: `delimiter` option](https://eslint.style/rules/member-delimiter-style#delimiter)
20
- * to add a trailing delimiter to the last item in multi-line interfaces and type aliases.
21
- *
22
- * @default 'always-multiline'
23
- *
24
- * @see [@stylistic/comma-dangle](https://eslint.style/rules/comma-dangle)
25
- */
26
- trailingComma?: Exclude<RuleOptions<'@stylistic/comma-dangle'>, object>;
27
-
28
- /**
29
- * Enforce a consistent delimiter style in interfaces and type aliases.
30
- *
31
- * @default 'comma'
32
- *
33
- * @see [@stylistic/member-delimiter-style: `delimiter` option](https://eslint.style/rules/member-delimiter-style#delimiter)
34
- */
35
- memberDelimiterStyle?: RuleOptions<'@stylistic/member-delimiter-style'>['singleline']['delimiter'];
36
-
37
- /**
38
- * The style of quotes to use for strings.
39
- *
40
- * @default 'single'
41
- *
42
- * @see [@stylistic/quotes](https://eslint.style/rules/quotes)
43
- */
44
- quotes?: RuleOptions<'@stylistic/quotes'>;
45
-
46
- /**
47
- * The style of quotes to use for JSX attributes.
48
- *
49
- * @default 'prefer-double'
50
- *
51
- * @see [@stylistic/jsx-quotes](https://eslint.style/rules/jsx-quotes)
52
- */
53
- jsxQuotes?: RuleOptions<'@stylistic/jsx-quotes'>;
54
-
55
- /**
56
- * Add parentheses around arrow function parameters.
57
- *
58
- * @default 'always'
59
- *
60
- * @see [@stylistic/arrow-parens](https://eslint.style/rules/arrow-parens)
61
- */
62
- arrowParens?: RuleOptions<'@stylistic/arrow-parens'>;
63
-
64
- /**
65
- * Use tabs for indentation.
66
- *
67
- * This is used by
68
- * - [vue/html-indent](https://eslint.vuejs.org/rules/html-indent)
69
- * - [@html-eslint/indent](https://html-eslint.org/docs/rules/indent)
70
- * - [@stylistic/indent](https://eslint.style/rules/indent)
71
- * - [@stylistic/no-tabs](https://eslint.style/rules/no-tabs)
72
- * - [@stylistic/indent-binary-ops](https://eslint.style/rules/indent-binary-ops)
73
- * - [better-tailwindcss/enforce-consistent-line-wrapping](https://github.com/schoero/eslint-plugin-better-tailwindcss/blob/main/docs/rules/enforce-consistent-line-wrapping.md)
74
- *
75
- * @default true
76
- */
77
- useTabs?: boolean;
78
-
79
- /**
80
- * The number of space characters used for indentation.
81
- *
82
- * If `stylistic.useTabs` is `true`, this determines the number of space characters that each tab indentation consists of.
83
- *
84
- * This is used by
85
- * - [vue/max-len](https://eslint.vuejs.org/rules/max-len)
86
- * - [vue/html-indent](https://eslint.vuejs.org/rules/html-indent)
87
- * - [vue/html-comment-indent](https://eslint.vuejs.org/rules/html-comment-indent.html)
88
- * - [@stylistic/indent](https://eslint.style/rules/indent)
89
- * - [@stylistic/max-len](https://eslint.style/rules/max-len)
90
- * - [@stylistic/indent-binary-ops](https://eslint.style/rules/indent-binary-ops)
91
- * - [perfectionist/sort-imports: `maxLineLength` option](https://perfectionist.dev/rules/sort-imports#maxlinelength)
92
- * - [better-tailwindcss/enforce-consistent-line-wrapping: `indent` option](https://github.com/schoero/eslint-plugin-better-tailwindcss/blob/main/docs/rules/enforce-consistent-line-wrapping.md)
93
- *
94
- * @default 2
95
- */
96
- indent?: number;
97
-
98
- /**
99
- * Maximum number of consecutive empty lines.
100
- *
101
- * This is used by
102
- * - [vue/block-tag-newline: `maxEmptyLines` option](https://eslint.vuejs.org/rules/block-tag-newline#options)
103
- * - [@html-eslint/no-multiple-empty-lines: `max` option](https://html-eslint.org/docs/rules/no-multiple-empty-lines)
104
- *
105
- * @default 1
106
- */
107
- maxConsecutiveEmptyLines?: RuleOptions<'@stylistic/no-multiple-empty-lines'>['max'];
108
-
109
- /**
110
- * Maximum line length for the code. Strings, texts, and comments are ignored.
111
- *
112
- * This is used by
113
- * - [vue/max-len](https://eslint.vuejs.org/rules/max-len)
114
- * - [@stylistic/max-len](https://eslint.style/rules/max-len)
115
- * - [perfectionist/sort-imports: `maxLineLength` option](https://perfectionist.dev/rules/sort-imports#maxlinelength)
116
- * - [better-tailwindcss/enforce-consistent-line-wrapping: `printWidth` option](https://github.com/schoero/eslint-plugin-better-tailwindcss/blob/main/docs/rules/enforce-consistent-line-wrapping.md)
117
- *
118
- * @default 120
119
- */
120
- maxLineLength?: number;
121
-
122
- /**
123
- * Maximum number of HTML attributes per line.
124
- *
125
- * This is used by
126
- * - [vue/max-attributes-per-line: `singleline.max` option](https://eslint.vuejs.org/rules/max-attributes-per-line)
127
- * - [@html-eslint/attrs-newline: `ifAttrsMoreThan` option](https://html-eslint.dev/rules/attrs-newline)
128
- *
129
- * @default 3
130
- */
131
- maxAttributesPerLine?: number;
132
-
133
- /**
134
- * Require void HTML elements to be self-closing.
135
- *
136
- * This is used by
137
- * - [vue/html-self-closing: `html.void` option](https://eslint.vuejs.org/rules/html-self-closing.html#options)
138
- * - [@html-eslint/require-closing-tags: `selfClosing` option](https://html-eslint.org/docs/rules/require-closing-tags#options)
139
- *
140
- * @default 'always'
141
- */
142
- selfCloseVoidHTMLElements?: 'never' | 'always';
143
- }
144
- //#endregion
145
- export { type StylisticOptions };
@@ -1,46 +0,0 @@
1
- import { RuleOptions } from "../eslintRules.cjs";
2
- import { ConfigWithOverrides } from "../index.cjs";
3
-
4
- //#region src/types/configOptions/tailwind.d.ts
5
- interface BaseTailwindOptions extends ConfigWithOverrides {
6
- /** Path to the _tailwind.config.js_ file, relative to the current working directory (**v3**).
7
- *
8
- * @see [better-tailwindcss: `tailwindConfig` option](https://github.com/schoero/eslint-plugin-better-tailwindcss/blob/main/docs/settings/settings.md#tailwindconfig)
9
- */
10
- config?: string;
11
-
12
- /** Path to the CSS-based Tailwind config file, relative to the current working directory (**only v4**).
13
- *
14
- * @see [better-tailwindcss: `entryPoint` option](https://github.com/schoero/eslint-plugin-better-tailwindcss/blob/main/docs/settings/settings.md#entrypoint)
15
- */
16
- entryPoint?: string;
17
-
18
- /**
19
- * Enforce breaking Tailwind classes into multiple lines if they exceed the line length defined by `stylistic.maxLineLength`.
20
- *
21
- * @default true
22
- *
23
- * @see [better-tailwindcss/enforce-consistent-line-wrapping](https://github.com/schoero/eslint-plugin-better-tailwindcss/blob/main/docs/rules/enforce-consistent-line-wrapping.md)
24
- */
25
- multilineSort?: boolean;
26
-
27
- /**
28
- * Regex patterns of unregistered class names that should be ignored.
29
- *
30
- * [Component classes](https://tailwindcss.com/docs/adding-custom-styles#adding-component-classes) are detected automatically and don't need to be ignored.
31
- *
32
- * @default []
33
- *
34
- * @see [better-tailwindcss/no-unregistered-classes: `ignore` option](https://github.com/schoero/eslint-plugin-better-tailwindcss/blob/main/docs/rules/no-unregistered-classes.md#ignore)
35
- */
36
- ignoredUnregisteredClasses?: RuleOptions<'better-tailwindcss/no-unregistered-classes'>['ignore'];
37
- }
38
- interface EntryPointRequired {
39
- entryPoint: string;
40
- }
41
- interface ConfigRequired {
42
- config: string;
43
- }
44
- type TailwindOptions = BaseTailwindOptions & (ConfigRequired | EntryPointRequired);
45
- //#endregion
46
- export { type TailwindOptions };
@@ -1,55 +0,0 @@
1
- import { RuleOptions } from "../eslintRules.cjs";
2
- import { ConfigWithOverrides } from "../index.cjs";
3
-
4
- //#region src/types/configOptions/test.d.ts
5
- interface TestOptions {
6
- /**
7
- * Use [eslint-plugin-storybook](https://github.com/storybookjs/eslint-plugin-storybook) to enforce best practices and code styles for Storybook stories and tests.
8
- *
9
- * @default false // `true` if "storybook" is detected in the package.json file when `autoDetectDeps` is enabled
10
- */
11
- storybook?: boolean | ConfigWithOverrides;
12
-
13
- /**
14
- * Use [eslint-plugin-vitest](https://github.com/vitest-dev/eslint-plugin-vitest) to enforce best practices and code styles for Vitest tests.
15
- *
16
- * @default false // `true` if "vitest" is detected in the package.json file when `autoDetectDeps` is enabled
17
- */
18
- vitest?: boolean | ConfigWithOverrides;
19
-
20
- /**
21
- * Use [eslint-plugin-playwright](https://github.com/playwright-community/eslint-plugin-playwright) to enforce best practices and code styles for Playwright tests.
22
- *
23
- * @default false // `true` if "@playwright/test" is detected in the package.json file when `autoDetectDeps` is enabled
24
- */
25
- playwright?: boolean | ConfigWithOverrides;
26
-
27
- /**
28
- * Use [eslint-plugin-cypress](https://github.com/cypress-io/eslint-plugin-cypress) to enforce best practices and code styles for Cypress tests.
29
- *
30
- * @default false // `true` if "cypress" is detected in the package.json file when `autoDetectDeps` is enabled
31
- */
32
- cypress?: boolean | ConfigWithOverrides;
33
-
34
- /**
35
- * Enforce the consistent use of either `test` or `it` as the test function.
36
- *
37
- * @default 'test'
38
- *
39
- * @see [vitest/consistent-test-it](https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/consistent-test-it.md)
40
- */
41
- testFunction?: RuleOptions<'vitest/consistent-test-it'>['fn'];
42
-
43
- /**
44
- * Enforce a maximum depth for nested `describe` calls to increase code clarity.
45
- *
46
- * This is used by
47
- * - [vitest/max-nested-describe](https://github.com/vitest-dev/eslint-plugin-vitest/blob/main/docs/rules/max-nested-describe.md)
48
- * - [playwright/max-nested-describe](https://github.com/playwright-community/eslint-plugin-playwright/blob/main/docs/rules/max-nested-describe.md)
49
- *
50
- * @default 1
51
- */
52
- maxNestedDescribe?: RuleOptions<'vitest/max-nested-describe'>['max'];
53
- }
54
- //#endregion
55
- export { type TestOptions };
@@ -1,36 +0,0 @@
1
- import { RuleOptions } from "../eslintRules.cjs";
2
- import { ConfigWithOverrides } from "../index.cjs";
3
-
4
- //#region src/types/configOptions/typescript.d.ts
5
- interface TypeScriptOptions extends ConfigWithOverrides {
6
- /**
7
- * Globs of files to allow running with the default project compiler options despite not being matched by the project service (_tsconfig.json_).
8
- *
9
- * The matched files may not also be included in their nearest _tsconfig.json_ file.
10
- *
11
- * @default []
12
- *
13
- * @see [@typescript-eslint: `allowDefaultProject` option](https://typescript-eslint.io/packages/parser#allowdefaultproject)
14
- */
15
- allowedDefaultProjects?: string[];
16
-
17
- /**
18
- * Enforce the consistent use of either `method` or `property` syntax for method signatures.
19
- *
20
- * @default 'method'
21
- *
22
- * @see [@typescript-eslint/method-signature-style](https://typescript-eslint.io/rules/method-signature-style)
23
- */
24
- methodSignatureStyle?: RuleOptions<'@typescript-eslint/method-signature-style'>;
25
-
26
- /**
27
- * Enforce the consistent use of either `interface` or `type` for type definitions.
28
- *
29
- * @default 'interface'
30
- *
31
- * @see [@typescript-eslint/consistent-type-definitions](https://typescript-eslint.io/rules/consistent-type-definitions)
32
- */
33
- typeDefinitionStyle?: RuleOptions<'@typescript-eslint/consistent-type-definitions'>;
34
- }
35
- //#endregion
36
- export { type TypeScriptOptions };
@@ -1,211 +0,0 @@
1
- import { RuleOptions } from "../eslintRules.cjs";
2
- import { VueAccessibilityOptions } from "./vueAccessibility.cjs";
3
- import { ConfigWithOverrides } from "../index.cjs";
4
-
5
- //#region src/types/configOptions/vue.d.ts
6
- interface BlockLang {
7
- style?: 'css' | 'scss' | 'postcss' | 'implicit';
8
- script?: 'js' | 'ts' | 'jsx' | 'tsx' | 'implicit';
9
- }
10
- type Macro = 'definePage' | 'defineModel' | 'defineProps' | 'defineEmits' | 'defineSlots' | 'defineCustom' | 'defineExpose' | 'defineOptions';
11
- type SFCBlock = 'docs' | 'template' | 'script[setup]' | 'style[scoped]' | 'i18n[locale=en]' | 'script:not([setup])' | 'style:not([scoped])' | 'i18n:not([locale=en])';
12
- type VBindStyleSameNameShorthandOptions = RuleOptions<'vue/v-bind-style', 1>['sameNameShorthand'];
13
- interface VueOptions extends ConfigWithOverrides {
14
- /**
15
- * Use [eslint-plugin-vuejs-accessibility](https://vue-a11y.github.io/eslint-plugin-vuejs-accessibility) to enforce accessibility standards in SFCs.
16
- *
17
- * @default true
18
- */
19
- accessibility?: boolean | VueAccessibilityOptions;
20
-
21
- /**
22
- * The order of top-level blocks in SFCs.
23
- *
24
- * @default
25
- * [
26
- * 'script:not([setup])',
27
- * 'script[setup]',
28
- * 'template',
29
- * 'i18n[locale=en]',
30
- * 'i18n:not([locale=en])',
31
- * 'style:not([scoped])',
32
- * 'style[scoped]',
33
- * 'docs',
34
- * ]
35
- *
36
- * @see [vue/block-order](https://eslint.vuejs.org/rules/block-order)
37
- */
38
- blocksOrder?: SFCBlock[];
39
-
40
- /**
41
- * The order of compiler macros in `<script setup>`.
42
- *
43
- * @default
44
- * [
45
- * 'definePage',
46
- * 'defineOptions',
47
- * 'defineModel',
48
- * 'defineProps',
49
- * 'defineEmits',
50
- * 'defineSlots',
51
- * 'defineCustom',
52
- * 'defineExpose',
53
- * ]
54
- *
55
- * @see [vue/define-macros-order](https://eslint.vuejs.org/rules/define-macros-order)
56
- */
57
- macrosOrder?: Macro[];
58
-
59
- /**
60
- * The order of HTML and Vue attributes.
61
- *
62
- * @default
63
- * [
64
- * 'DEFINITION',
65
- * 'CONDITIONALS',
66
- * 'RENDER_MODIFIERS',
67
- * 'LIST_RENDERING',
68
- * 'UNIQUE',
69
- * 'GLOBAL',
70
- * 'TWO_WAY_BINDING',
71
- * 'SLOT',
72
- * 'CONTENT',
73
- * 'OTHER_DIRECTIVES',
74
- * 'EVENTS',
75
- * 'ATTR_SHORTHAND_BOOL',
76
- * 'ATTR_DYNAMIC',
77
- * 'ATTR_STATIC',
78
- * ]
79
- *
80
- * @see [vue/attributes-order](https://eslint.vuejs.org/rules/attributes-order)
81
- */
82
- attributesOrder?: RuleOptions<'vue/attributes-order'>['order'];
83
-
84
- /**
85
- * Whether attributes should be hyphenated.
86
- *
87
- * @default 'never'
88
- *
89
- * @see [vue/attribute-hyphenation](https://eslint.vuejs.org/rules/attribute-hyphenation)
90
- */
91
- attributeHyphenation?: RuleOptions<'vue/attribute-hyphenation'>;
92
-
93
- /**
94
- * Enforce consistent use of the `v-bind` same-name shorthand style.
95
- *
96
- * @default 'always'
97
- *
98
- * @see [vue/v-bind-style: `sameNameShorthand` option](https://eslint.vuejs.org/rules/v-bind-style#options)
99
- */
100
- preferVBindSameNameShorthand?: Exclude<VBindStyleSameNameShorthandOptions, 'ignore'>;
101
-
102
- /**
103
- * Require the shorthand form of the attribute when `v-bind`'s value is `true`.
104
- *
105
- * @default 'always'
106
- *
107
- * @see [vue/prefer-true-attribute-shorthand](https://eslint.vuejs.org/rules/prefer-true-attribute-shorthand)
108
- */
109
- preferVBindTrueShorthand?: RuleOptions<'vue/prefer-true-attribute-shorthand'>;
110
-
111
- /**
112
- * Enforce the use of specific attributes such as `scoped` and `module` on top-level `<style>` blocks.
113
- *
114
- * @default ['scoped', 'module']
115
- *
116
- * @see [vue/enforce-style-attribute: `allow` option](https://eslint.vuejs.org/rules/enforce-style-attribute#options)
117
- */
118
- allowedStyleAttributes?: RuleOptions<'vue/enforce-style-attribute'>['allow'];
119
-
120
- /**
121
- * The language for top-lever SFC blocks.
122
- *
123
- * Use `implicit` to omit the `lang` attribute, which defaults to `css` for `<style>`, and `js` for `<script>`.
124
- *
125
- * @default
126
- * {
127
- * script: 'js', // `'ts'` if "typescript" is detected in the package.json file when `autoDetectDeps` is enabled
128
- * style: 'implicit',
129
- * }
130
- *
131
- * @see [vue/block-lang](https://eslint.vuejs.org/rules/block-lang)
132
- */
133
- blockLang?: BlockLang;
134
-
135
- /**
136
- * Enforce a consistent style for destructuring props.
137
- *
138
- * @default 'always'
139
- *
140
- * @see [vue/define-props-destructuring: `destructure` option](https://eslint.vuejs.org/rules/define-props-destructuring#options)
141
- */
142
- destructureProps?: RuleOptions<'vue/define-props-destructuring'>['destructure'];
143
-
144
- /**
145
- * Enforce consistent casing for component names in `<template>` blocks.
146
- *
147
- * @default 'PascalCase'
148
- *
149
- * @see [vue/component-name-in-template-casing](https://eslint.vuejs.org/rules/component-name-in-template-casing)
150
- */
151
- componentNameCaseInTemplate?: RuleOptions<'vue/component-name-in-template-casing'>;
152
-
153
- /**
154
- * The delimiter used in `v-for` directives.
155
- *
156
- * @default 'in'
157
- *
158
- * @see [vue/v-for-delimiter-style](https://eslint.vuejs.org/rules/v-for-delimiter-style)
159
- */
160
- vForDelimiterStyle?: RuleOptions<'vue/v-for-delimiter-style'>;
161
-
162
- /**
163
- * Enforce a consistent handler style in `v-on` directives.
164
- *
165
- * @default ['method', 'inline-function']
166
- *
167
- * @see [vue/v-on-handler-style](https://eslint.vuejs.org/rules/v-on-handler-style)
168
- */
169
- vOnHandlerStyle?: RuleOptions<'vue/v-on-handler-style'>;
170
-
171
- /**
172
- * Disallow certain elements and components.
173
- *
174
- * When NuxtUI or NuxtImage are enabled, certain HTML elements (e.g., `<img>`, `<a>`, `<form>`, `<input>`) are disallowed in favor of their alternative components.
175
- *
176
- * New items extend the defaults, they don't override it.
177
- *
178
- * @default []
179
- *
180
- * @see [vue/no-restricted-html-elements](https://eslint.vuejs.org/rules/no-restricted-html-elements)
181
- */
182
- restrictedElements?: RuleOptions<'vue/no-restricted-html-elements'>[];
183
-
184
- /**
185
- * Disallow certain static attributes.
186
- *
187
- * @default []
188
- *
189
- * @see [vue/no-restricted-static-attribute](https://eslint.vuejs.org/rules/no-restricted-static-attribute)
190
- */
191
- restrictedStaticAttributes?: RuleOptions<'vue/no-restricted-static-attribute'>[];
192
-
193
- /**
194
- * Regex patterns of undefined component names that should be ignored.
195
- *
196
- * This is useful for ignoring components that are globally registered or defined in a way that ESLint cannot detect.
197
- *
198
- * New items extend the defaults, they don't override it.
199
- *
200
- * @default
201
- * [
202
- * '^(Nuxt|U)',
203
- * '^(Icon|Html|Head|Title|Base|Meta|Link|Style|Body|NoScript)$',
204
- * ]
205
- *
206
- * @see [vue/no-undef-components](https://eslint.vuejs.org/rules/no-undef-components)
207
- */
208
- ignoredUndefinedComponents?: string[];
209
- }
210
- //#endregion
211
- export { type VueOptions };
@@ -1,34 +0,0 @@
1
- import { RuleOptions } from "../eslintRules.cjs";
2
-
3
- //#region src/types/configOptions/vueAccessibility.d.ts
4
- type AnchorHasContentRuleOptions = RuleOptions<'vuejs-accessibility/anchor-has-content'>;
5
- interface VueAccessibilityOptions {
6
- /**
7
- * Names of components that render an `<a>` element.
8
- *
9
- * @default ['RouterLink', 'NuxtLink', 'ULink']
10
- *
11
- * @see [vuejs-accessibility/anchor-has-content: `components` option](https://vue-a11y.github.io/eslint-plugin-vuejs-accessibility/rules/anchor-has-content#%F0%9F%94%A7-options)
12
- */
13
- anchorComponents?: AnchorHasContentRuleOptions['components'];
14
-
15
- /**
16
- * Names of components that render an `<img>` element.
17
- *
18
- * @default ['NuxtImg']
19
- *
20
- * @see [vuejs-accessibility/alt-text: `img` option](https://vue-a11y.github.io/eslint-plugin-vuejs-accessibility/rules/alt-text#%F0%9F%94%A7-options)
21
- */
22
- imageComponents?: RuleOptions<'vuejs-accessibility/alt-text'>['img'];
23
-
24
- /**
25
- * Names of components that should be considered accessible child elements.
26
- *
27
- * @default ['img', 'picture', 'NuxtImg', 'NuxtPicture']
28
- *
29
- * @see [vuejs-accessibility/anchor-has-content: `accessibleChildren` option](https://vue-a11y.github.io/eslint-plugin-vuejs-accessibility/rules/anchor-has-content#%F0%9F%94%A7-options)
30
- */
31
- accessibleChildComponents?: AnchorHasContentRuleOptions['accessibleChildren'];
32
- }
33
- //#endregion
34
- export { type VueAccessibilityOptions };