@shayanthenerd/eslint-config 0.14.0 → 0.16.0

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 (53) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +209 -190
  3. package/dist/configs/astro.mjs +34 -0
  4. package/dist/configs/base.mjs +19 -10
  5. package/dist/configs/css.mjs +2 -2
  6. package/dist/configs/cypress.mjs +2 -2
  7. package/dist/configs/html.mjs +2 -3
  8. package/dist/configs/importX.mjs +8 -4
  9. package/dist/configs/oxlintOverrides.mjs +20 -14
  10. package/dist/configs/perfectionist.mjs +8 -4
  11. package/dist/configs/playwright.mjs +2 -2
  12. package/dist/configs/restrictedExports.mjs +1 -1
  13. package/dist/configs/storybook.mjs +2 -2
  14. package/dist/configs/stylistic.mjs +8 -4
  15. package/dist/configs/tailwind.mjs +14 -14
  16. package/dist/configs/typescript.mjs +8 -4
  17. package/dist/configs/vitest.mjs +2 -2
  18. package/dist/configs/vue.mjs +2 -2
  19. package/dist/configs/vueComponentNames.mjs +1 -1
  20. package/dist/configs/vueServerComponents.mjs +1 -1
  21. package/dist/configs/zod.mjs +8 -4
  22. package/dist/{utils → helpers}/globs.mjs +2 -1
  23. package/dist/{utils → helpers}/ignores/defaultIgnorePatterns.mjs +3 -1
  24. package/dist/{utils → helpers}/ignores/getIgnorePatterns.mjs +1 -1
  25. package/dist/{utils → helpers}/ignores/resolveGitignorePatterns.mjs +1 -1
  26. package/dist/{utils → helpers}/isPackageDetected.mjs +1 -1
  27. package/dist/{utils → helpers}/options/defaultOptions.mjs +15 -7
  28. package/dist/{utils → helpers}/options/enableDetectedConfigs.mjs +2 -3
  29. package/dist/{utils → helpers}/options/mergeWithDefaults.mjs +4 -5
  30. package/dist/{utils → helpers}/vue/getRestrictedVueElements.mjs +1 -1
  31. package/dist/{utils → helpers}/vue/getRestrictedVueInputs.mjs +1 -1
  32. package/dist/index.mjs +6 -4
  33. package/dist/oxlint.config.jsonc +120 -206
  34. package/dist/prettier.config.mjs +1 -1
  35. package/dist/rules/astro.mjs +61 -0
  36. package/dist/rules/css.mjs +1 -1
  37. package/dist/rules/html.mjs +3 -3
  38. package/dist/rules/importX.mjs +1 -1
  39. package/dist/rules/javascript.mjs +1 -2
  40. package/dist/rules/perfectionist.mjs +2 -2
  41. package/dist/rules/stylistic.mjs +10 -7
  42. package/dist/rules/tailwind.mjs +4 -4
  43. package/dist/rules/typescript.mjs +2 -2
  44. package/dist/rules/vue.mjs +6 -6
  45. package/dist/rules/vueAccessibility.mjs +1 -1
  46. package/dist/types/configOptions/base.d.mts +8 -8
  47. package/dist/types/configOptions/nuxt.d.mts +3 -3
  48. package/dist/types/configOptions/stylistic.d.mts +0 -15
  49. package/dist/types/configOptions/test.d.mts +4 -4
  50. package/dist/types/configOptions/vue.d.mts +1 -1
  51. package/dist/types/eslint-schema.d.mts +1031 -237
  52. package/dist/types/index.d.mts +46 -20
  53. package/package.json +142 -124
@@ -1,208 +1,122 @@
1
1
  {
2
- "$schema": "../node_modules/oxlint/configuration_schema.json",
3
-
4
- "env": {
5
- "builtin": true,
6
- "es2026": true,
7
- "commonjs": false,
8
- "node": true,
9
- "browser": true,
10
- "worker": true,
11
- "serviceworker": false,
12
- "webextensions": false
13
- },
14
-
15
- "categories": {
16
- "correctness": "error",
17
- "suspicious": "error",
18
- "restriction": "error",
19
- "pedantic": "error",
20
- "perf": "warn",
21
- "style": "warn",
22
- "nursery": "error"
23
- },
24
-
25
- "plugins": [
26
- "oxc",
27
- "vue",
28
- "node",
29
- "jest",
30
- "jsdoc",
31
- "eslint",
32
- "import",
33
- "vitest",
34
- "promise",
35
- "unicorn",
36
- "jsx-a11y",
37
- "typescript"
38
- ],
39
-
40
- "rules": {
41
- /*** OXC ***/
42
- "oxc/no-async-await": "off",
43
- "oxc/no-optional-chaining": "off",
44
- "oxc/no-rest-spread-properties": "off",
45
-
46
- /*** ESLint ***/
47
- "eslint/yoda": "error",
48
- "eslint/alert": "warn",
49
- "eslint/id-length": "off",
50
- "eslint/sort-vars": "off",
51
- "eslint/sort-keys": "off",
52
- "eslint/no-ternary": "off",
53
- "eslint/no-undefined": "off",
54
- "eslint/sort-imports": "off",
55
- "eslint/max-statements": "off",
56
- "eslint/no-else-return": "off",
57
- "eslint/arrow-body-style": "off",
58
- "eslint/no-magic-numbers": "off",
59
- "eslint/no-inline-comments": "off",
60
- "eslint/capitalized-comments": "off",
61
- "eslint/func-names": ["error", "as-needed"],
62
- "no-sequences": ["error", { "allowInParentheses": false }],
63
- "eslint/no-plusplus": ["warn", { "allowForLoopAfterthoughts": true }],
64
- "eslint/no-unused-vars": ["error", { "ignoreUsingDeclarations": true }],
65
- "eslint/no-duplicate-imports": ["error", { "allowSeparateTypeImports": true }],
66
- "eslint/grouped-accessor-pairs": ["warn", "anyOrder", { "enforceForTSTypes": true }],
67
- "eslint/no-console": [
68
- "warn",
69
- {
70
- "allow": ["info", "warn", "error", "table", "group", "groupEnd", "groupCollapsed"]
71
- }
72
- ],
73
-
74
- /*** TypeScript ***/
75
- "typescript/triple-slash-reference": "off",
76
- "typescript/strict-boolean-expressions": "off",
77
- "typescript/explicit-function-return-type": "off",
78
- "typescript/explicit-module-boundary-types": "off",
79
- "typescript/consistent-indexed-object-style": ["warn", "record"],
80
-
81
- /*** Import ***/
82
- "import/extensions": "off",
83
- "import/unambiguous": "off",
84
- "import/no-namespace": "off",
85
- "import/exports-last": "off",
86
- "import/no-named-export": "off",
87
- "import/max-dependencies": "off",
88
- "import/no-default-export": "off",
89
- "import/prefer-default-export": "off",
90
- "import/no-named-as-default-member": "off",
91
- "import/no-anonymous-default-export": "off",
92
-
93
- /*** Unicorn ***/
94
- "unicorn/no-null": "off",
95
- "unicorn/filename-case": "off",
96
- "unicorn/prefer-set-has": "off",
97
- "unicorn/no-array-reduce": "off",
98
- "unicorn/prefer-string-raw": "off",
99
- "unicorn/no-array-for-each": "off",
100
- "unicorn/prefer-global-this": "off",
101
- "unicorn/no-useless-undefined": "off",
102
- "unicorn/no-immediate-mutation": "warn",
103
- "unicorn/prefer-prototype-methods": "off",
104
- "unicorn/no-await-expression-member": "off",
105
-
106
- /*** Jest ***/
107
- "jest/require-hook": "off",
108
- "jest/prefer-lowercase-title": "warn",
109
- "jest/require-top-level-describe": "off",
110
-
111
- /*** JSDoc ***/
112
- "jsdoc/require-param": "off",
113
- "jsdoc/require-returns": "off",
114
- "jsdoc/require-property": "off",
115
-
116
- /*** Vue ***/
117
- "vue/max-props": "off",
118
- "vue/no-required-prop-with-default": "off",
119
-
120
- /*** Customizable Overrides ***/
121
- /* These rules are customizable in the ESLint config, but OXLint doesn't respect them. */
122
- "eslint/max-depth": "off",
123
- "eslint/func-style": "off",
124
- "eslint/max-nested-callbacks": "off",
125
- "typescript/consistent-type-definitions": "off",
126
- "vitest/consistent-test-it": "off",
127
- "jest/max-nested-describe": "off",
128
- "vue/define-props-destructuring": "off"
129
- },
130
-
131
- "overrides": [
132
- {
133
- "files": ["**/{src,app,server}/**/*.{vue,js,mjs,cjs,jsx,ts,mts,cts,tsx}"],
134
- "rules": {
135
- "eslint/no-undef": "off"
136
- }
137
- }
138
- ],
139
-
140
- "ignorePatterns": [
141
- /* Dependencies */
142
- "**/*.min.*",
143
- "**/jspm_packages",
144
- "**/pnpm-lock.yaml",
145
- "**/bower_components",
146
- "**/package-lock.json",
147
-
148
- /* Auto-generated type definitions */
149
- "**/typegen.d.ts",
150
- "**/components.d.ts",
151
- "**/auto-import?(s).d.ts",
152
-
153
- /* Build outputs */
154
- "**/out",
155
- "**/dist",
156
- "**/build",
157
- "**/.data",
158
- "**/output",
159
- "**/.output",
160
- "**/.serverless",
161
- "**/public/build",
162
- "**/public/static",
163
- "**/.eslint-config-inspector",
164
-
165
- /* Cache */
166
- "**/tmp",
167
- "**/.tmp",
168
- "**/.npm",
169
- "**/temp",
170
- "**/.temp",
171
- "**/cache",
172
- "**/.cache",
173
- "**/deno_dir",
174
- "**/.parcel-cache",
175
- "**/*.lerna_backup",
176
- "**/.postcss-cache",
177
- "**/.vitepress/cache",
178
- "**/vite.config.*.timestamp-*",
179
-
180
- /* Frameworks and tools */
181
- "**/.nx",
182
- "**/.vite",
183
- "**/.yarn",
184
- "**/.nuxt",
185
- "**/.next",
186
- "**/.vitest",
187
- "**/.vercel",
188
- "**/.svelte-kit",
189
- "**/.vite-inspect",
190
-
191
- /* Tests */
192
- "**/coverage",
193
- "**/_fixtures",
194
- "**/.nyc_output",
195
- "**/__snapshots__",
196
-
197
- /* Development environment */
198
- "**/.idea",
199
- "**/.fleet",
200
- "**/.history",
201
-
202
- // Documentation
203
- "**/LICENSE*",
204
- "**/CHANGELOG*.md",
205
- "**/CODEOWNERS.md",
206
- "**/CODE_OF_CONDUCT.md"
207
- ]
2
+ "$schema": "../node_modules/oxlint/configuration_schema.json",
3
+
4
+ "plugins": [
5
+ "oxc",
6
+ "vue",
7
+ "node",
8
+ "jest",
9
+ "jsdoc",
10
+ "eslint",
11
+ "import",
12
+ "vitest",
13
+ "promise",
14
+ "unicorn",
15
+ "jsx-a11y",
16
+ "typescript"
17
+ ],
18
+
19
+ "rules": {
20
+ /*** OXC ***/
21
+ "oxc/no-async-await": "off",
22
+ "oxc/no-optional-chaining": "off",
23
+ "oxc/no-rest-spread-properties": "off",
24
+
25
+ /*** ESLint ***/
26
+ "eslint/alert": "warn",
27
+ "eslint/arrow-body-style": "off",
28
+ "eslint/capitalized-comments": "off",
29
+ "eslint/func-names": ["error", "as-needed"],
30
+ "eslint/grouped-accessor-pairs": ["warn", "anyOrder", { "enforceForTSTypes": true }],
31
+ "eslint/id-length": "off",
32
+ "eslint/max-statements": "off",
33
+ "eslint/no-console": [
34
+ "warn",
35
+ {
36
+ "allow": ["info", "warn", "error", "table", "group", "groupEnd", "groupCollapsed"]
37
+ }
38
+ ],
39
+ "eslint/no-continue": "off",
40
+ "eslint/no-duplicate-imports": ["error", { "allowSeparateTypeImports": true }],
41
+ "eslint/no-else-return": "off",
42
+ "eslint/no-inline-comments": "off",
43
+ "eslint/no-magic-numbers": "off",
44
+ "eslint/no-plusplus": ["warn", { "allowForLoopAfterthoughts": true }],
45
+ "eslint/no-sequences": ["error", { "allowInParentheses": false }],
46
+ "eslint/no-ternary": "off",
47
+ "eslint/no-undefined": "off",
48
+ "eslint/no-unused-vars": ["error", { "ignoreUsingDeclarations": true }],
49
+ "eslint/prefer-destructuring": ["warn", { "array": false }],
50
+ "eslint/sort-imports": "off",
51
+ "eslint/sort-keys": "off",
52
+ "eslint/sort-vars": "off",
53
+ "eslint/yoda": "error",
54
+ "no-sequences": ["error", { "allowInParentheses": false }],
55
+
56
+ /*** TypeScript ***/
57
+ "typescript/consistent-indexed-object-style": ["warn", "record"],
58
+ "typescript/explicit-function-return-type": "off",
59
+ "typescript/explicit-module-boundary-types": "off",
60
+ "typescript/strict-boolean-expressions": "off",
61
+ "typescript/triple-slash-reference": "off",
62
+
63
+ /*** Import ***/
64
+ "import/extensions": "off",
65
+ "import/exports-last": "off",
66
+ "import/max-dependencies": "off",
67
+ "import/no-anonymous-default-export": "off",
68
+ "import/no-default-export": "off",
69
+ "import/no-named-as-default-member": "off",
70
+ "import/no-named-export": "off",
71
+ "import/no-namespace": "off",
72
+ "import/no-unassigned-import": "off",
73
+ "import/prefer-default-export": "off",
74
+ "import/unambiguous": "off",
75
+
76
+ /*** Unicorn ***/
77
+ "unicorn/filename-case": "off",
78
+ "unicorn/no-array-for-each": "off",
79
+ "unicorn/no-array-reduce": "off",
80
+ "unicorn/no-await-expression-member": "off",
81
+ "unicorn/no-immediate-mutation": "warn",
82
+ "unicorn/no-null": "off",
83
+ "unicorn/no-useless-undefined": "off",
84
+ "unicorn/prefer-global-this": "off",
85
+ "unicorn/prefer-prototype-methods": "off",
86
+ "unicorn/prefer-set-has": "off",
87
+ "unicorn/prefer-string-raw": "off",
88
+
89
+ /*** Jest ***/
90
+ "jest/prefer-lowercase-title": "warn",
91
+ "jest/require-hook": "off",
92
+ "jest/require-top-level-describe": "off",
93
+
94
+ /*** JSDoc ***/
95
+ "jsdoc/require-param": "off",
96
+ "jsdoc/require-property": "off",
97
+ "jsdoc/require-returns": "off",
98
+
99
+ /*** Vue ***/
100
+ "vue/max-props": "off",
101
+ "vue/no-required-prop-with-default": "off",
102
+
103
+ /*** Customizable Overrides ***/
104
+ /* These rules are customizable in the ESLint config, but the customizations aren't reflected here. */
105
+ "eslint/func-style": "off",
106
+ "eslint/max-depth": "off",
107
+ "eslint/max-nested-callbacks": "off",
108
+ "typescript/consistent-type-definitions": "off",
109
+ "vitest/consistent-test-it": "off",
110
+ "jest/max-nested-describe": "off",
111
+ "vue/define-props-destructuring": "off"
112
+ },
113
+
114
+ "overrides": [
115
+ {
116
+ "files": ["**/{src,app,server}/**/*.{vue,js,mjs,cjs,jsx,ts,mts,cts,tsx}"],
117
+ "rules": {
118
+ "eslint/no-undef": "off"
119
+ }
120
+ }
121
+ ]
208
122
  }
@@ -1,7 +1,7 @@
1
1
  //#region src/prettier.config.ts
2
2
  const prettierConfig = {
3
3
  semi: true,
4
- useTabs: true,
4
+ useTabs: false,
5
5
  tabWidth: 2,
6
6
  vueIndentScriptAndStyle: false,
7
7
  printWidth: 120,
@@ -0,0 +1,61 @@
1
+ //#region src/rules/astro.ts
2
+ function getAstroRules() {
3
+ return {
4
+ "import-x/exports-last": "off",
5
+ "@stylistic/jsx-one-expression-per-line": "off",
6
+ "astro/missing-client-only-directive-value": "error",
7
+ "astro/no-conflict-set-directives": "error",
8
+ "astro/no-deprecated-astro-canonicalurl": "error",
9
+ "astro/no-deprecated-astro-fetchcontent": "error",
10
+ "astro/no-deprecated-astro-resolve": "error",
11
+ "astro/no-deprecated-getentrybyslug": "error",
12
+ "astro/no-exports-from-components": "error",
13
+ "astro/no-unused-define-vars-in-style": "warn",
14
+ "astro/valid-compile": "error",
15
+ "astro/no-set-html-directive": "warn",
16
+ "astro/no-unsafe-inline-scripts": "warn",
17
+ "astro/no-set-text-directive": "warn",
18
+ "astro/no-unused-css-selector": "warn",
19
+ "astro/prefer-class-list-directive": "warn",
20
+ "astro/prefer-split-class-list": "warn",
21
+ "astro/jsx-a11y/alt-text": "error",
22
+ "astro/jsx-a11y/anchor-ambiguous-text": "warn",
23
+ "astro/jsx-a11y/anchor-has-content": "warn",
24
+ "astro/jsx-a11y/anchor-is-valid": "error",
25
+ "astro/jsx-a11y/aria-activedescendant-has-tabindex": "warn",
26
+ "astro/jsx-a11y/aria-props": "error",
27
+ "astro/jsx-a11y/aria-proptypes": "error",
28
+ "astro/jsx-a11y/aria-role": "warn",
29
+ "astro/jsx-a11y/aria-unsupported-elements": "error",
30
+ "astro/jsx-a11y/autocomplete-valid": "error",
31
+ "astro/jsx-a11y/click-events-have-key-events": "warn",
32
+ "astro/jsx-a11y/control-has-associated-label": "warn",
33
+ "astro/jsx-a11y/heading-has-content": "warn",
34
+ "astro/jsx-a11y/html-has-lang": "error",
35
+ "astro/jsx-a11y/iframe-has-title": "warn",
36
+ "astro/jsx-a11y/img-redundant-alt": "warn",
37
+ "astro/jsx-a11y/interactive-supports-focus": "warn",
38
+ "astro/jsx-a11y/label-has-associated-control": "warn",
39
+ "astro/jsx-a11y/lang": "error",
40
+ "astro/jsx-a11y/media-has-caption": "warn",
41
+ "astro/jsx-a11y/mouse-events-have-key-events": "warn",
42
+ "astro/jsx-a11y/no-access-key": "warn",
43
+ "astro/jsx-a11y/no-aria-hidden-on-focusable": "error",
44
+ "astro/jsx-a11y/no-autofocus": "warn",
45
+ "astro/jsx-a11y/no-distracting-elements": "warn",
46
+ "astro/jsx-a11y/no-interactive-element-to-noninteractive-role": "warn",
47
+ "astro/jsx-a11y/no-noninteractive-element-interactions": "warn",
48
+ "astro/jsx-a11y/no-noninteractive-element-to-interactive-role": "warn",
49
+ "astro/jsx-a11y/no-noninteractive-tabindex": "warn",
50
+ "astro/jsx-a11y/no-redundant-roles": "warn",
51
+ "astro/jsx-a11y/no-static-element-interactions": "warn",
52
+ "astro/jsx-a11y/prefer-tag-over-role": "warn",
53
+ "astro/jsx-a11y/role-has-required-aria-props": "warn",
54
+ "astro/jsx-a11y/role-supports-aria-props": "warn",
55
+ "astro/jsx-a11y/scope": "error",
56
+ "astro/jsx-a11y/tabindex-no-positive": "warn"
57
+ };
58
+ }
59
+
60
+ //#endregion
61
+ export { getAstroRules };
@@ -1,5 +1,5 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
3
 
4
4
  //#region src/rules/css.ts
5
5
  const allowedPhysicalUnits = [
@@ -1,11 +1,11 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
3
 
4
4
  //#region src/rules/html.ts
5
5
  function getHTMLRules(options) {
6
6
  const { html, tailwind, stylistic } = options.configs;
7
7
  const { useBaseline, idNamingConvention } = isEnabled(html) ? html : defaultOptions.configs.html;
8
- const { indent, useTabs, maxAttributesPerLine, maxConsecutiveEmptyLines, selfCloseVoidHTMLElements } = isEnabled(stylistic) ? stylistic : defaultOptions.configs.stylistic;
8
+ const { indent, maxAttributesPerLine, maxConsecutiveEmptyLines, selfCloseVoidHTMLElements } = isEnabled(stylistic) ? stylistic : defaultOptions.configs.stylistic;
9
9
  const htmlRules = {
10
10
  "@html-eslint/no-duplicate-attrs": "error",
11
11
  "@html-eslint/no-duplicate-class": "warn",
@@ -51,7 +51,7 @@ function getHTMLRules(options) {
51
51
  "@html-eslint/attrs-newline": ["warn", { ifAttrsMoreThan: maxAttributesPerLine }],
52
52
  "@html-eslint/element-newline": ["warn", { inline: ["$inline"] }],
53
53
  "@html-eslint/id-naming-convention": ["warn", idNamingConvention],
54
- "@html-eslint/indent": ["warn", useTabs ? "tab" : indent],
54
+ "@html-eslint/indent": ["warn", indent],
55
55
  "@html-eslint/lowercase": "warn",
56
56
  "@html-eslint/no-extra-spacing-attrs": ["warn", {
57
57
  disallowTabs: true,
@@ -1,5 +1,5 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
3
  import path from "node:path";
4
4
 
5
5
  //#region src/rules/importX.ts
@@ -100,7 +100,6 @@ function getJavaScriptRules(options) {
100
100
  "groupEnd",
101
101
  "groupCollapsed"
102
102
  ] }],
103
- "no-continue": "warn",
104
103
  "no-empty": "warn",
105
104
  "no-empty-function": ["error", { allow: [
106
105
  "overrideMethods",
@@ -193,7 +192,7 @@ function getJavaScriptRules(options) {
193
192
  "operator-assignment": "error",
194
193
  "prefer-arrow-callback": ["warn", { allowUnboundThis: true }],
195
194
  "prefer-const": "error",
196
- "prefer-destructuring": "warn",
195
+ "prefer-destructuring": ["warn", { array: false }],
197
196
  "prefer-exponentiation-operator": "warn",
198
197
  "prefer-named-capture-group": "warn",
199
198
  "prefer-numeric-literals": "warn",
@@ -1,5 +1,5 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
3
 
4
4
  //#region src/rules/perfectionist.ts
5
5
  function getPerfectionistRules(options) {
@@ -15,7 +15,7 @@ function getPerfectionistRules(options) {
15
15
  "perfectionist/sort-named-imports": "warn",
16
16
  "perfectionist/sort-named-exports": "warn",
17
17
  "perfectionist/sort-imports": ["warn", {
18
- environment: env,
18
+ environment: env === "bun" ? "bun" : "node",
19
19
  tsconfig: tsConfig || void 0,
20
20
  sortSideEffects: true,
21
21
  fallbackSort: {
@@ -1,10 +1,10 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
3
 
4
4
  //#region src/rules/stylistic.ts
5
5
  function getStylisticRules(options) {
6
6
  const { stylistic } = options.configs;
7
- const { semi, quotes, indent, useTabs, jsxQuotes, arrowParens, trailingComma, maxLineLength, maxAttributesPerLine, memberDelimiterStyle, maxConsecutiveEmptyLines } = isEnabled(stylistic) ? stylistic : defaultOptions.configs.stylistic;
7
+ const { semi, quotes, indent, jsxQuotes, arrowParens, trailingComma, maxLineLength, maxAttributesPerLine, memberDelimiterStyle, maxConsecutiveEmptyLines } = isEnabled(stylistic) ? stylistic : defaultOptions.configs.stylistic;
8
8
  return {
9
9
  "@stylistic/array-bracket-newline": ["warn", "consistent"],
10
10
  "@stylistic/array-bracket-spacing": "warn",
@@ -28,13 +28,13 @@ function getStylisticRules(options) {
28
28
  "@stylistic/implicit-arrow-linebreak": ["warn", "beside"],
29
29
  "@stylistic/indent": [
30
30
  "warn",
31
- useTabs ? "tab" : indent,
31
+ indent,
32
32
  {
33
33
  tabLength: indent,
34
34
  SwitchCase: 1
35
35
  }
36
36
  ],
37
- "@stylistic/indent-binary-ops": ["warn", useTabs ? "tab" : indent],
37
+ "@stylistic/indent-binary-ops": ["warn", indent],
38
38
  "@stylistic/jsx-closing-bracket-location": "warn",
39
39
  "@stylistic/jsx-closing-tag-location": "warn",
40
40
  "@stylistic/jsx-curly-brace-presence": "warn",
@@ -43,7 +43,7 @@ function getStylisticRules(options) {
43
43
  "@stylistic/jsx-equals-spacing": "warn",
44
44
  "@stylistic/jsx-first-prop-new-line": "warn",
45
45
  "@stylistic/jsx-function-call-newline": "warn",
46
- "@stylistic/jsx-indent-props": ["warn", useTabs ? "tab" : indent],
46
+ "@stylistic/jsx-indent-props": ["warn", indent],
47
47
  "@stylistic/jsx-max-props-per-line": ["warn", { maximum: {
48
48
  multi: 1,
49
49
  single: maxAttributesPerLine
@@ -63,7 +63,10 @@ function getStylisticRules(options) {
63
63
  allowArrayStart: true,
64
64
  allowModuleStart: true,
65
65
  allowObjectStart: true,
66
- allowInterfaceStart: true
66
+ allowInterfaceStart: true,
67
+ afterHashbangComment: true,
68
+ applyDefaultIgnorePatterns: false,
69
+ ignorePattern: "@ts|eslint|oxlint"
67
70
  }],
68
71
  "@stylistic/max-len": ["warn", {
69
72
  tabWidth: indent,
@@ -96,7 +99,7 @@ function getStylisticRules(options) {
96
99
  maxEOF: 0,
97
100
  max: maxConsecutiveEmptyLines
98
101
  }],
99
- "@stylistic/no-tabs": useTabs ? "off" : "warn",
102
+ "@stylistic/no-tabs": "warn",
100
103
  "@stylistic/no-trailing-spaces": "warn",
101
104
  "@stylistic/no-whitespace-before-property": "warn",
102
105
  "@stylistic/nonblock-statement-body-position": "warn",
@@ -1,17 +1,17 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
3
 
4
4
  //#region src/rules/tailwind.ts
5
5
  function getTailwindRules(options) {
6
6
  const { tailwind, stylistic } = options.configs;
7
7
  const { multilineSort, ignoredUnregisteredClasses: userIgnoredUnregisteredClasses } = isEnabled(tailwind) ? tailwind : defaultOptions.configs.tailwind;
8
- const { indent, useTabs, maxLineLength } = isEnabled(stylistic) ? stylistic : defaultOptions.configs.stylistic;
8
+ const { indent, maxLineLength } = isEnabled(stylistic) ? stylistic : defaultOptions.configs.stylistic;
9
9
  const isTailwindV4 = isEnabled(tailwind) && tailwind.entryPoint;
10
10
  const tailwindRules = {
11
11
  "better-tailwindcss/enforce-consistent-line-wrapping": [multilineSort ? "warn" : "off", {
12
+ indent,
12
13
  preferSingleLine: true,
13
- printWidth: maxLineLength,
14
- indent: useTabs ? "tab" : indent
14
+ printWidth: maxLineLength
15
15
  }],
16
16
  "better-tailwindcss/enforce-consistent-class-order": "warn",
17
17
  "better-tailwindcss/enforce-consistent-variable-syntax": "warn",
@@ -1,5 +1,5 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
3
 
4
4
  //#region src/rules/typescript.ts
5
5
  function getTypeScriptRules(options) {
@@ -126,7 +126,7 @@ function getTypeScriptRules(options) {
126
126
  "@typescript-eslint/prefer-string-starts-ends-with": "warn",
127
127
  "@typescript-eslint/no-loop-func": "error",
128
128
  "@typescript-eslint/default-param-last": "warn",
129
- "@typescript-eslint/prefer-destructuring": "warn",
129
+ "@typescript-eslint/prefer-destructuring": ["warn", { array: false }],
130
130
  "@typescript-eslint/promise-function-async": "error",
131
131
  "@typescript-eslint/consistent-type-imports": "warn",
132
132
  "@typescript-eslint/no-useless-empty-export": "error",
@@ -1,12 +1,12 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
3
- import { getRestrictedVueInputs } from "../utils/vue/getRestrictedVueInputs.mjs";
4
- import { getRestrictedVueElements } from "../utils/vue/getRestrictedVueElements.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
+ import { getRestrictedVueInputs } from "../helpers/vue/getRestrictedVueInputs.mjs";
4
+ import { getRestrictedVueElements } from "../helpers/vue/getRestrictedVueElements.mjs";
5
5
 
6
6
  //#region src/rules/vue.ts
7
7
  function getVueRules(options) {
8
8
  const { typescript, stylistic, tailwind, vue, nuxt } = options.configs;
9
- const { indent, useTabs, trailingComma, maxLineLength, maxAttributesPerLine, maxConsecutiveEmptyLines, selfCloseVoidHTMLElements } = isEnabled(stylistic) ? stylistic : defaultOptions.configs.stylistic;
9
+ const { indent, trailingComma, maxLineLength, maxAttributesPerLine, maxConsecutiveEmptyLines, selfCloseVoidHTMLElements } = isEnabled(stylistic) ? stylistic : defaultOptions.configs.stylistic;
10
10
  const { blockLang, blocksOrder, macrosOrder, attributesOrder, destructureProps, vForDelimiterStyle, attributeHyphenation, allowedStyleAttributes, preferVBindTrueShorthand, componentNameCaseInTemplate, preferVBindSameNameShorthand, restrictedElements: userRestrictedElements, ignoredUndefinedComponents: userIgnoredUndefinedComponents, restrictedStaticAttributes: userRestrictedStaticAttributes } = isEnabled(vue) ? vue : defaultOptions.configs.vue;
11
11
  const isNuxtEnabled = isEnabled(nuxt);
12
12
  const isNuxtImageEnabled = isNuxtEnabled ? nuxt.image : void 0;
@@ -115,7 +115,7 @@ function getVueRules(options) {
115
115
  "vue/html-closing-bracket-newline": "warn",
116
116
  "vue/html-closing-bracket-spacing": "warn",
117
117
  "vue/html-end-tags": "warn",
118
- "vue/html-indent": ["warn", useTabs ? "tab" : indent],
118
+ "vue/html-indent": ["warn", indent],
119
119
  "vue/html-quotes": "warn",
120
120
  "vue/html-self-closing": ["error", { html: {
121
121
  normal: "never",
@@ -259,7 +259,7 @@ function getVueRules(options) {
259
259
  "vue/html-button-has-type": "error",
260
260
  "vue/html-comment-content-newline": "warn",
261
261
  "vue/html-comment-content-spacing": "warn",
262
- "vue/html-comment-indent": ["warn", useTabs ? "tab" : indent],
262
+ "vue/html-comment-indent": ["warn", indent],
263
263
  "vue/match-component-file-name": ["error", {
264
264
  shouldMatchCase: true,
265
265
  extensions: isEnabled(typescript) ? [
@@ -1,5 +1,5 @@
1
1
  import { isEnabled } from "../utils/isEnabled.mjs";
2
- import { defaultOptions } from "../utils/options/defaultOptions.mjs";
2
+ import { defaultOptions } from "../helpers/options/defaultOptions.mjs";
3
3
 
4
4
  //#region src/rules/vueAccessibility.ts
5
5
  function getVueAccessibilityRules(options) {