@kikiutils/eslint-config 6.0.0 → 7.0.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.
@@ -1 +1 @@
1
- {"version":3,"file":"base.d.ts","names":[],"sources":["../src/base.ts"],"mappings":";;;iBASgB,iBAAA,CAAkB,WAAA,oBAAuC,mBAAA"}
1
+ {"version":3,"file":"base.d.ts","names":[],"sources":["../src/base.ts"],"mappings":";;;iBAYgB,iBAAA,CAAkB,WAAA,oBAAuC,mBAAA"}
package/dist/base.js CHANGED
@@ -1,167 +1,212 @@
1
1
  import promise from "eslint-plugin-promise";
2
-
3
2
  //#region src/base.ts
4
3
  const basePerfectionistSortOptions = {
5
4
  ignoreCase: false,
6
5
  type: "natural"
7
6
  };
8
7
  function createBaseConfigs(environment = "node") {
9
- return [{
10
- files: ["**/*.{cjs,js,mjs,ts,tsx}"],
11
- rules: { "node/prefer-global/process": ["error", "always"] }
12
- }, {
13
- files: ["**/*.{cjs,js,mjs,ts,tsx,vue}"],
14
- plugins: { promise },
15
- rules: {
16
- "antfu/consistent-list-newline": ["error", {
17
- ArrayExpression: false,
18
- ArrayPattern: false
19
- }],
20
- "antfu/curly": "off",
21
- "antfu/if-newline": "off",
22
- "antfu/no-top-level-await": "off",
23
- "curly": ["error", "multi-line"],
24
- "max-classes-per-file": ["error", 1],
25
- "no-promise-executor-return": ["error", { allowVoid: true }],
26
- "perfectionist/sort-array-includes": ["error", basePerfectionistSortOptions],
27
- "perfectionist/sort-enums": ["error", {
28
- ...basePerfectionistSortOptions,
29
- sortByValue: "never"
30
- }],
31
- "perfectionist/sort-heritage-clauses": ["error", {
32
- ignoreCase: false,
33
- type: "natural"
34
- }],
35
- "perfectionist/sort-imports": ["error", {
36
- environment,
37
- groups: [
38
- "side-effect",
39
- "side-effect-style",
40
- "style",
41
- ["value-builtin", "type-builtin"],
42
- ["value-external", "type-external"],
43
- ["value-internal", "type-internal"],
44
- ["value-parent", "type-parent"],
45
- ["value-sibling", "type-sibling"],
46
- ["value-index", "type-index"],
47
- "unknown"
48
- ],
49
- ignoreCase: false,
50
- internalPattern: [
51
- "^#.*",
52
- "^@/.*",
53
- "^~/.*"
54
- ],
55
- type: "natural"
56
- }],
57
- "perfectionist/sort-interfaces": ["error", basePerfectionistSortOptions],
58
- "perfectionist/sort-intersection-types": ["error", basePerfectionistSortOptions],
59
- "perfectionist/sort-maps": ["error", basePerfectionistSortOptions],
60
- "perfectionist/sort-modules": ["error", {
61
- ...basePerfectionistSortOptions,
62
- groups: [
63
- "declare-type",
64
- ["export-type", "type"],
65
- "declare-interface",
66
- ["export-interface", "interface"],
67
- "declare-enum",
68
- ["enum", "export-enum"],
69
- "declare-class",
70
- ["class", "export-class"],
71
- "declare-function",
72
- ["export-function", "function"]
8
+ return [
9
+ { rules: {
10
+ "e18e/ban-dependencies": ["error", { allowed: ["axios"] }],
11
+ "e18e/prefer-static-regex": ["off"]
12
+ } },
13
+ {
14
+ files: ["**/*.{cjs,js,mjs}"],
15
+ plugins: { promise },
16
+ rules: {
17
+ ...createBaseRules(environment),
18
+ "node/prefer-global/process": ["error", "always"]
19
+ }
20
+ },
21
+ {
22
+ files: ["**/*.{ts,tsx}"],
23
+ plugins: { promise },
24
+ rules: {
25
+ ...createBaseRules(environment),
26
+ "node/prefer-global/process": ["error", "always"],
27
+ "ts/consistent-generic-constructors": ["error", "constructor"],
28
+ "ts/no-redeclare": "off"
29
+ }
30
+ },
31
+ {
32
+ files: ["**/.vscode/*.json"],
33
+ rules: {
34
+ "jsonc/sort-array-values": ["error", {
35
+ order: {
36
+ natural: true,
37
+ type: "asc"
38
+ },
39
+ pathPattern: "^.*$"
40
+ }],
41
+ "jsonc/sort-keys": [
42
+ "error",
43
+ "asc",
44
+ {
45
+ caseSensitive: true,
46
+ natural: true
47
+ }
73
48
  ]
74
- }],
75
- "perfectionist/sort-object-types": ["error", basePerfectionistSortOptions],
76
- "perfectionist/sort-objects": ["error", basePerfectionistSortOptions],
77
- "perfectionist/sort-sets": ["error", basePerfectionistSortOptions],
78
- "perfectionist/sort-switch-case": ["error", {
79
- ignoreCase: false,
80
- type: "natural"
81
- }],
82
- "perfectionist/sort-union-types": ["error", basePerfectionistSortOptions],
83
- "perfectionist/sort-variable-declarations": ["error", basePerfectionistSortOptions],
84
- "promise/no-multiple-resolved": "error",
85
- "promise/no-return-in-finally": "error",
86
- "promise/no-return-wrap": "error",
87
- "require-await": "error",
88
- "style/array-bracket-newline": ["error", { multiline: true }],
89
- "style/array-element-newline": ["error", {
90
- ArrayExpression: {
91
- consistent: true,
92
- minItems: 2
93
- },
94
- ArrayPattern: { minItems: 3 }
95
- }],
96
- "style/arrow-parens": ["error", "always"],
97
- "style/brace-style": [
98
- "error",
99
- "1tbs",
100
- { allowSingleLine: false }
101
- ],
102
- "style/function-call-spacing": ["error", "never"],
103
- "style/indent": ["error", 4],
104
- "style/max-len": ["warn", {
105
- code: 120,
106
- comments: 120
107
- }],
108
- "style/member-delimiter-style": ["error", { multiline: {
109
- delimiter: "semi",
110
- requireLast: true
111
- } }],
112
- "style/no-extra-parens": [
113
- "error",
114
- "all",
115
- { nestedBinaryExpressions: false }
116
- ],
117
- "style/no-extra-semi": "error",
118
- "style/object-curly-newline": ["error", {
119
- ExportDeclaration: {
120
- minProperties: 2,
121
- multiline: true
122
- },
123
- ImportDeclaration: {
124
- minProperties: 2,
125
- multiline: true
126
- },
127
- ObjectExpression: {
128
- minProperties: 2,
129
- multiline: true
130
- },
131
- ObjectPattern: {
132
- minProperties: 3,
133
- multiline: true
134
- }
135
- }],
136
- "style/operator-linebreak": [
137
- "error",
138
- "before",
139
- { overrides: { "=": "after" } }
49
+ }
50
+ },
51
+ {
52
+ files: ["**/*.{vue}"],
53
+ plugins: { promise },
54
+ rules: {
55
+ ...createBaseRules(environment),
56
+ "ts/consistent-generic-constructors": ["error", "constructor"],
57
+ "ts/no-redeclare": "off"
58
+ }
59
+ }
60
+ ];
61
+ }
62
+ function createBaseRules(environment = "node") {
63
+ return {
64
+ "antfu/consistent-list-newline": ["error", {
65
+ ArrayExpression: false,
66
+ ArrayPattern: false
67
+ }],
68
+ "antfu/curly": "off",
69
+ "antfu/if-newline": "off",
70
+ "antfu/no-top-level-await": "off",
71
+ "curly": ["error", "multi-line"],
72
+ "max-classes-per-file": ["error", 1],
73
+ "no-promise-executor-return": ["error", { allowVoid: true }],
74
+ "perfectionist/sort-array-includes": ["error", basePerfectionistSortOptions],
75
+ "perfectionist/sort-enums": ["error", {
76
+ ...basePerfectionistSortOptions,
77
+ sortByValue: "never"
78
+ }],
79
+ "perfectionist/sort-heritage-clauses": ["error", {
80
+ ignoreCase: false,
81
+ type: "natural"
82
+ }],
83
+ "perfectionist/sort-imports": ["error", {
84
+ environment,
85
+ groups: [
86
+ "side-effect",
87
+ "side-effect-style",
88
+ "style",
89
+ ["value-builtin", "type-builtin"],
90
+ ["value-external", "type-external"],
91
+ ["value-internal", "type-internal"],
92
+ ["value-parent", "type-parent"],
93
+ ["value-sibling", "type-sibling"],
94
+ ["value-index", "type-index"],
95
+ "unknown"
140
96
  ],
141
- "style/padding-line-between-statements": [
142
- "error",
143
- {
144
- blankLine: "always",
145
- next: [
146
- "class",
147
- "enum",
148
- "function"
149
- ],
150
- prev: "*"
151
- },
152
- {
153
- blankLine: "always",
154
- next: "*",
155
- prev: ["class", "function"]
156
- }
97
+ ignoreCase: false,
98
+ internalPattern: [
99
+ "^#.*",
100
+ "^@/.*",
101
+ "^~/.*"
157
102
  ],
158
- "style/semi": ["error", "always"],
159
- "ts/consistent-generic-constructors": ["error", "constructor"],
160
- "ts/no-redeclare": "off"
161
- }
162
- }];
103
+ type: "natural"
104
+ }],
105
+ "perfectionist/sort-interfaces": ["error", basePerfectionistSortOptions],
106
+ "perfectionist/sort-intersection-types": ["error", basePerfectionistSortOptions],
107
+ "perfectionist/sort-maps": ["error", basePerfectionistSortOptions],
108
+ "perfectionist/sort-modules": ["error", {
109
+ ...basePerfectionistSortOptions,
110
+ groups: [
111
+ "declare-type",
112
+ ["export-type", "type"],
113
+ "declare-interface",
114
+ ["export-interface", "interface"],
115
+ "declare-enum",
116
+ ["enum", "export-enum"],
117
+ "declare-class",
118
+ ["class", "export-class"],
119
+ "declare-function",
120
+ ["export-function", "function"]
121
+ ]
122
+ }],
123
+ "perfectionist/sort-object-types": ["error", basePerfectionistSortOptions],
124
+ "perfectionist/sort-objects": ["error", basePerfectionistSortOptions],
125
+ "perfectionist/sort-sets": ["error", basePerfectionistSortOptions],
126
+ "perfectionist/sort-switch-case": ["error", {
127
+ ignoreCase: false,
128
+ type: "natural"
129
+ }],
130
+ "perfectionist/sort-union-types": ["error", basePerfectionistSortOptions],
131
+ "perfectionist/sort-variable-declarations": ["error", basePerfectionistSortOptions],
132
+ "promise/no-multiple-resolved": "error",
133
+ "promise/no-return-in-finally": "error",
134
+ "promise/no-return-wrap": "error",
135
+ "require-await": "error",
136
+ "style/array-bracket-newline": ["error", { multiline: true }],
137
+ "style/array-element-newline": ["error", {
138
+ ArrayExpression: {
139
+ consistent: true,
140
+ minItems: 2
141
+ },
142
+ ArrayPattern: { minItems: 3 }
143
+ }],
144
+ "style/arrow-parens": ["error", "always"],
145
+ "style/brace-style": [
146
+ "error",
147
+ "1tbs",
148
+ { allowSingleLine: false }
149
+ ],
150
+ "style/function-call-spacing": ["error", "never"],
151
+ "style/indent": ["error", 4],
152
+ "style/max-len": ["warn", {
153
+ code: 120,
154
+ comments: 120
155
+ }],
156
+ "style/member-delimiter-style": ["error", { multiline: {
157
+ delimiter: "semi",
158
+ requireLast: true
159
+ } }],
160
+ "style/no-extra-parens": [
161
+ "error",
162
+ "all",
163
+ { nestedBinaryExpressions: false }
164
+ ],
165
+ "style/no-extra-semi": "error",
166
+ "style/object-curly-newline": ["error", {
167
+ ExportDeclaration: {
168
+ minProperties: 2,
169
+ multiline: true
170
+ },
171
+ ImportDeclaration: {
172
+ minProperties: 2,
173
+ multiline: true
174
+ },
175
+ ObjectExpression: {
176
+ minProperties: 2,
177
+ multiline: true
178
+ },
179
+ ObjectPattern: {
180
+ minProperties: 3,
181
+ multiline: true
182
+ }
183
+ }],
184
+ "style/operator-linebreak": [
185
+ "error",
186
+ "before",
187
+ { overrides: { "=": "after" } }
188
+ ],
189
+ "style/padding-line-between-statements": [
190
+ "error",
191
+ {
192
+ blankLine: "always",
193
+ next: [
194
+ "class",
195
+ "enum",
196
+ "function"
197
+ ],
198
+ prev: "*"
199
+ },
200
+ {
201
+ blankLine: "always",
202
+ next: "*",
203
+ prev: ["class", "function"]
204
+ }
205
+ ],
206
+ "style/semi": ["error", "always"]
207
+ };
163
208
  }
164
-
165
209
  //#endregion
166
210
  export { createBaseConfigs };
211
+
167
212
  //# sourceMappingURL=base.js.map
package/dist/base.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"base.js","names":[],"sources":["../src/base.ts"],"sourcesContent":["import type { TypedFlatConfigItem } from '@antfu/eslint-config';\n// @ts-expect-error No declare file.\nimport promise from 'eslint-plugin-promise';\n\nconst basePerfectionistSortOptions = {\n ignoreCase: false,\n type: 'natural',\n} as const;\n\nexport function createBaseConfigs(environment: 'bun' | 'node' = 'node'): TypedFlatConfigItem[] {\n return [\n {\n files: ['**/*.{cjs,js,mjs,ts,tsx}'],\n rules: {\n 'node/prefer-global/process': [\n 'error',\n 'always',\n ],\n },\n },\n {\n files: ['**/*.{cjs,js,mjs,ts,tsx,vue}'],\n plugins: { promise },\n rules: {\n 'antfu/consistent-list-newline': [\n 'error',\n {\n ArrayExpression: false,\n ArrayPattern: false,\n },\n ],\n 'antfu/curly': 'off',\n 'antfu/if-newline': 'off',\n 'antfu/no-top-level-await': 'off',\n 'curly': [\n 'error',\n 'multi-line',\n ],\n 'max-classes-per-file': [\n 'error',\n 1,\n ],\n 'no-promise-executor-return': [\n 'error',\n { allowVoid: true },\n ],\n 'perfectionist/sort-array-includes': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-enums': [\n 'error',\n {\n ...basePerfectionistSortOptions,\n sortByValue: 'never',\n },\n ],\n 'perfectionist/sort-heritage-clauses': [\n 'error',\n {\n ignoreCase: false,\n type: 'natural',\n },\n ],\n 'perfectionist/sort-imports': [\n 'error',\n {\n environment,\n groups: [\n 'side-effect',\n 'side-effect-style',\n 'style',\n [\n 'value-builtin',\n 'type-builtin',\n ],\n [\n 'value-external',\n 'type-external',\n ],\n [\n 'value-internal',\n 'type-internal',\n ],\n [\n 'value-parent',\n 'type-parent',\n ],\n [\n 'value-sibling',\n 'type-sibling',\n ],\n [\n 'value-index',\n 'type-index',\n ],\n 'unknown',\n ],\n ignoreCase: false,\n internalPattern: [\n '^#.*',\n '^@/.*',\n '^~/.*',\n ],\n type: 'natural',\n },\n ],\n 'perfectionist/sort-interfaces': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-intersection-types': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-maps': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-modules': [\n 'error',\n {\n ...basePerfectionistSortOptions,\n groups: [\n 'declare-type',\n [\n 'export-type',\n 'type',\n ],\n 'declare-interface',\n [\n 'export-interface',\n 'interface',\n ],\n 'declare-enum',\n [\n 'enum',\n 'export-enum',\n ],\n 'declare-class',\n [\n 'class',\n 'export-class',\n ],\n 'declare-function',\n [\n 'export-function',\n 'function',\n ],\n ],\n },\n ],\n 'perfectionist/sort-object-types': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-objects': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-sets': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-switch-case': [\n 'error',\n {\n ignoreCase: false,\n type: 'natural',\n },\n ],\n 'perfectionist/sort-union-types': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-variable-declarations': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'promise/no-multiple-resolved': 'error',\n 'promise/no-return-in-finally': 'error',\n 'promise/no-return-wrap': 'error',\n 'require-await': 'error',\n 'style/array-bracket-newline': [\n 'error',\n { multiline: true },\n ],\n 'style/array-element-newline': [\n 'error',\n {\n ArrayExpression: {\n consistent: true,\n minItems: 2,\n },\n ArrayPattern: { minItems: 3 },\n },\n ],\n 'style/arrow-parens': [\n 'error',\n 'always',\n ],\n 'style/brace-style': [\n 'error',\n '1tbs',\n { allowSingleLine: false },\n ],\n 'style/function-call-spacing': [\n 'error',\n 'never',\n ],\n 'style/indent': [\n 'error',\n 4,\n ],\n 'style/max-len': [\n 'warn',\n {\n code: 120,\n comments: 120,\n },\n ],\n 'style/member-delimiter-style': [\n 'error',\n {\n multiline: {\n delimiter: 'semi',\n requireLast: true,\n },\n },\n ],\n 'style/no-extra-parens': [\n 'error',\n 'all',\n { nestedBinaryExpressions: false },\n ],\n 'style/no-extra-semi': 'error',\n 'style/object-curly-newline': [\n 'error',\n {\n ExportDeclaration: {\n minProperties: 2,\n multiline: true,\n },\n ImportDeclaration: {\n minProperties: 2,\n multiline: true,\n },\n ObjectExpression: {\n minProperties: 2,\n multiline: true,\n },\n ObjectPattern: {\n minProperties: 3,\n multiline: true,\n },\n },\n ],\n 'style/operator-linebreak': [\n 'error',\n 'before',\n { overrides: { '=': 'after' } },\n ],\n 'style/padding-line-between-statements': [\n 'error',\n {\n blankLine: 'always',\n next: [\n 'class',\n 'enum',\n 'function',\n ],\n prev: '*',\n },\n {\n blankLine: 'always',\n next: '*',\n prev: [\n 'class',\n 'function',\n ],\n },\n ],\n 'style/semi': [\n 'error',\n 'always',\n ],\n 'ts/consistent-generic-constructors': [\n 'error',\n 'constructor',\n ],\n 'ts/no-redeclare': 'off',\n },\n },\n ];\n}\n"],"mappings":";;;AAIA,MAAM,+BAA+B;CACjC,YAAY;CACZ,MAAM;CACT;AAED,SAAgB,kBAAkB,cAA8B,QAA+B;AAC3F,QAAO,CACH;EACI,OAAO,CAAC,2BAA2B;EACnC,OAAO,EACH,8BAA8B,CAC1B,SACA,SACH,EACJ;EACJ,EACD;EACI,OAAO,CAAC,+BAA+B;EACvC,SAAS,EAAE,SAAS;EACpB,OAAO;GACH,iCAAiC,CAC7B,SACA;IACI,iBAAiB;IACjB,cAAc;IACjB,CACJ;GACD,eAAe;GACf,oBAAoB;GACpB,4BAA4B;GAC5B,SAAS,CACL,SACA,aACH;GACD,wBAAwB,CACpB,SACA,EACH;GACD,8BAA8B,CAC1B,SACA,EAAE,WAAW,MAAM,CACtB;GACD,qCAAqC,CACjC,SACA,6BACH;GACD,4BAA4B,CACxB,SACA;IACI,GAAG;IACH,aAAa;IAChB,CACJ;GACD,uCAAuC,CACnC,SACA;IACI,YAAY;IACZ,MAAM;IACT,CACJ;GACD,8BAA8B,CAC1B,SACA;IACI;IACA,QAAQ;KACJ;KACA;KACA;KACA,CACI,iBACA,eACH;KACD,CACI,kBACA,gBACH;KACD,CACI,kBACA,gBACH;KACD,CACI,gBACA,cACH;KACD,CACI,iBACA,eACH;KACD,CACI,eACA,aACH;KACD;KACH;IACD,YAAY;IACZ,iBAAiB;KACb;KACA;KACA;KACH;IACD,MAAM;IACT,CACJ;GACD,iCAAiC,CAC7B,SACA,6BACH;GACD,yCAAyC,CACrC,SACA,6BACH;GACD,2BAA2B,CACvB,SACA,6BACH;GACD,8BAA8B,CAC1B,SACA;IACI,GAAG;IACH,QAAQ;KACJ;KACA,CACI,eACA,OACH;KACD;KACA,CACI,oBACA,YACH;KACD;KACA,CACI,QACA,cACH;KACD;KACA,CACI,SACA,eACH;KACD;KACA,CACI,mBACA,WACH;KACJ;IACJ,CACJ;GACD,mCAAmC,CAC/B,SACA,6BACH;GACD,8BAA8B,CAC1B,SACA,6BACH;GACD,2BAA2B,CACvB,SACA,6BACH;GACD,kCAAkC,CAC9B,SACA;IACI,YAAY;IACZ,MAAM;IACT,CACJ;GACD,kCAAkC,CAC9B,SACA,6BACH;GACD,4CAA4C,CACxC,SACA,6BACH;GACD,gCAAgC;GAChC,gCAAgC;GAChC,0BAA0B;GAC1B,iBAAiB;GACjB,+BAA+B,CAC3B,SACA,EAAE,WAAW,MAAM,CACtB;GACD,+BAA+B,CAC3B,SACA;IACI,iBAAiB;KACb,YAAY;KACZ,UAAU;KACb;IACD,cAAc,EAAE,UAAU,GAAG;IAChC,CACJ;GACD,sBAAsB,CAClB,SACA,SACH;GACD,qBAAqB;IACjB;IACA;IACA,EAAE,iBAAiB,OAAO;IAC7B;GACD,+BAA+B,CAC3B,SACA,QACH;GACD,gBAAgB,CACZ,SACA,EACH;GACD,iBAAiB,CACb,QACA;IACI,MAAM;IACN,UAAU;IACb,CACJ;GACD,gCAAgC,CAC5B,SACA,EACI,WAAW;IACP,WAAW;IACX,aAAa;IAChB,EACJ,CACJ;GACD,yBAAyB;IACrB;IACA;IACA,EAAE,yBAAyB,OAAO;IACrC;GACD,uBAAuB;GACvB,8BAA8B,CAC1B,SACA;IACI,mBAAmB;KACf,eAAe;KACf,WAAW;KACd;IACD,mBAAmB;KACf,eAAe;KACf,WAAW;KACd;IACD,kBAAkB;KACd,eAAe;KACf,WAAW;KACd;IACD,eAAe;KACX,eAAe;KACf,WAAW;KACd;IACJ,CACJ;GACD,4BAA4B;IACxB;IACA;IACA,EAAE,WAAW,EAAE,KAAK,SAAS,EAAE;IAClC;GACD,yCAAyC;IACrC;IACA;KACI,WAAW;KACX,MAAM;MACF;MACA;MACA;MACH;KACD,MAAM;KACT;IACD;KACI,WAAW;KACX,MAAM;KACN,MAAM,CACF,SACA,WACH;KACJ;IACJ;GACD,cAAc,CACV,SACA,SACH;GACD,sCAAsC,CAClC,SACA,cACH;GACD,mBAAmB;GACtB;EACJ,CACJ"}
1
+ {"version":3,"file":"base.js","names":[],"sources":["../src/base.ts"],"sourcesContent":["import type {\n Rules,\n TypedFlatConfigItem,\n} from '@antfu/eslint-config';\n// @ts-expect-error No declare file.\nimport promise from 'eslint-plugin-promise';\n\nconst basePerfectionistSortOptions = {\n ignoreCase: false,\n type: 'natural',\n} as const;\n\nexport function createBaseConfigs(environment: 'bun' | 'node' = 'node'): TypedFlatConfigItem[] {\n return [\n // All files\n {\n rules: {\n 'e18e/ban-dependencies': [\n 'error',\n { allowed: ['axios'] },\n ],\n 'e18e/prefer-static-regex': ['off'],\n },\n },\n // JavaScript\n {\n files: ['**/*.{cjs,js,mjs}'],\n plugins: { promise },\n rules: {\n ...createBaseRules(environment),\n 'node/prefer-global/process': [\n 'error',\n 'always',\n ],\n },\n },\n // TypeScript\n {\n files: ['**/*.{ts,tsx}'],\n plugins: { promise },\n rules: {\n ...createBaseRules(environment),\n 'node/prefer-global/process': [\n 'error',\n 'always',\n ],\n 'ts/consistent-generic-constructors': [\n 'error',\n 'constructor',\n ],\n 'ts/no-redeclare': 'off',\n },\n },\n // VsCode jsonc\n {\n files: ['**/.vscode/*.json'],\n rules: {\n 'jsonc/sort-array-values': [\n 'error',\n {\n order: {\n natural: true,\n type: 'asc',\n },\n pathPattern: '^.*$',\n },\n ],\n 'jsonc/sort-keys': [\n 'error',\n 'asc',\n {\n caseSensitive: true,\n natural: true,\n },\n ],\n },\n },\n // Vue\n {\n files: ['**/*.{vue}'],\n plugins: { promise },\n rules: {\n ...createBaseRules(environment),\n 'ts/consistent-generic-constructors': [\n 'error',\n 'constructor',\n ],\n 'ts/no-redeclare': 'off',\n },\n },\n ];\n}\n\nfunction createBaseRules(environment: 'bun' | 'node' = 'node'): Rules {\n return {\n 'antfu/consistent-list-newline': [\n 'error',\n {\n ArrayExpression: false,\n ArrayPattern: false,\n },\n ],\n 'antfu/curly': 'off',\n 'antfu/if-newline': 'off',\n 'antfu/no-top-level-await': 'off',\n 'curly': [\n 'error',\n 'multi-line',\n ],\n 'max-classes-per-file': [\n 'error',\n 1,\n ],\n 'no-promise-executor-return': [\n 'error',\n { allowVoid: true },\n ],\n 'perfectionist/sort-array-includes': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-enums': [\n 'error',\n {\n ...basePerfectionistSortOptions,\n sortByValue: 'never',\n },\n ],\n 'perfectionist/sort-heritage-clauses': [\n 'error',\n {\n ignoreCase: false,\n type: 'natural',\n },\n ],\n 'perfectionist/sort-imports': [\n 'error',\n {\n environment,\n groups: [\n 'side-effect',\n 'side-effect-style',\n 'style',\n [\n 'value-builtin',\n 'type-builtin',\n ],\n [\n 'value-external',\n 'type-external',\n ],\n [\n 'value-internal',\n 'type-internal',\n ],\n [\n 'value-parent',\n 'type-parent',\n ],\n [\n 'value-sibling',\n 'type-sibling',\n ],\n [\n 'value-index',\n 'type-index',\n ],\n 'unknown',\n ],\n ignoreCase: false,\n internalPattern: [\n '^#.*',\n '^@/.*',\n '^~/.*',\n ],\n type: 'natural',\n },\n ],\n 'perfectionist/sort-interfaces': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-intersection-types': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-maps': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-modules': [\n 'error',\n {\n ...basePerfectionistSortOptions,\n groups: [\n 'declare-type',\n [\n 'export-type',\n 'type',\n ],\n 'declare-interface',\n [\n 'export-interface',\n 'interface',\n ],\n 'declare-enum',\n [\n 'enum',\n 'export-enum',\n ],\n 'declare-class',\n [\n 'class',\n 'export-class',\n ],\n 'declare-function',\n [\n 'export-function',\n 'function',\n ],\n ],\n },\n ],\n 'perfectionist/sort-object-types': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-objects': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-sets': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-switch-case': [\n 'error',\n {\n ignoreCase: false,\n type: 'natural',\n },\n ],\n 'perfectionist/sort-union-types': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'perfectionist/sort-variable-declarations': [\n 'error',\n basePerfectionistSortOptions,\n ],\n 'promise/no-multiple-resolved': 'error',\n 'promise/no-return-in-finally': 'error',\n 'promise/no-return-wrap': 'error',\n 'require-await': 'error',\n 'style/array-bracket-newline': [\n 'error',\n { multiline: true },\n ],\n 'style/array-element-newline': [\n 'error',\n {\n ArrayExpression: {\n consistent: true,\n minItems: 2,\n },\n ArrayPattern: { minItems: 3 },\n },\n ],\n 'style/arrow-parens': [\n 'error',\n 'always',\n ],\n 'style/brace-style': [\n 'error',\n '1tbs',\n { allowSingleLine: false },\n ],\n 'style/function-call-spacing': [\n 'error',\n 'never',\n ],\n 'style/indent': [\n 'error',\n 4,\n ],\n 'style/max-len': [\n 'warn',\n {\n code: 120,\n comments: 120,\n },\n ],\n 'style/member-delimiter-style': [\n 'error',\n {\n multiline: {\n delimiter: 'semi',\n requireLast: true,\n },\n },\n ],\n 'style/no-extra-parens': [\n 'error',\n 'all',\n { nestedBinaryExpressions: false },\n ],\n 'style/no-extra-semi': 'error',\n 'style/object-curly-newline': [\n 'error',\n {\n ExportDeclaration: {\n minProperties: 2,\n multiline: true,\n },\n ImportDeclaration: {\n minProperties: 2,\n multiline: true,\n },\n ObjectExpression: {\n minProperties: 2,\n multiline: true,\n },\n ObjectPattern: {\n minProperties: 3,\n multiline: true,\n },\n },\n ],\n 'style/operator-linebreak': [\n 'error',\n 'before',\n { overrides: { '=': 'after' } },\n ],\n 'style/padding-line-between-statements': [\n 'error',\n {\n blankLine: 'always',\n next: [\n 'class',\n 'enum',\n 'function',\n ],\n prev: '*',\n },\n {\n blankLine: 'always',\n next: '*',\n prev: [\n 'class',\n 'function',\n ],\n },\n ],\n 'style/semi': [\n 'error',\n 'always',\n ],\n };\n}\n"],"mappings":";;AAOA,MAAM,+BAA+B;CACjC,YAAY;CACZ,MAAM;CACT;AAED,SAAgB,kBAAkB,cAA8B,QAA+B;AAC3F,QAAO;EAEH,EACI,OAAO;GACH,yBAAyB,CACrB,SACA,EAAE,SAAS,CAAC,QAAQ,EAAE,CACzB;GACD,4BAA4B,CAAC,MAAM;GACtC,EACJ;EAED;GACI,OAAO,CAAC,oBAAoB;GAC5B,SAAS,EAAE,SAAS;GACpB,OAAO;IACH,GAAG,gBAAgB,YAAY;IAC/B,8BAA8B,CAC1B,SACA,SACH;IACJ;GACJ;EAED;GACI,OAAO,CAAC,gBAAgB;GACxB,SAAS,EAAE,SAAS;GACpB,OAAO;IACH,GAAG,gBAAgB,YAAY;IAC/B,8BAA8B,CAC1B,SACA,SACH;IACD,sCAAsC,CAClC,SACA,cACH;IACD,mBAAmB;IACtB;GACJ;EAED;GACI,OAAO,CAAC,oBAAoB;GAC5B,OAAO;IACH,2BAA2B,CACvB,SACA;KACI,OAAO;MACH,SAAS;MACT,MAAM;MACT;KACD,aAAa;KAChB,CACJ;IACD,mBAAmB;KACf;KACA;KACA;MACI,eAAe;MACf,SAAS;MACZ;KACJ;IACJ;GACJ;EAED;GACI,OAAO,CAAC,aAAa;GACrB,SAAS,EAAE,SAAS;GACpB,OAAO;IACH,GAAG,gBAAgB,YAAY;IAC/B,sCAAsC,CAClC,SACA,cACH;IACD,mBAAmB;IACtB;GACJ;EACJ;;AAGL,SAAS,gBAAgB,cAA8B,QAAe;AAClE,QAAO;EACH,iCAAiC,CAC7B,SACA;GACI,iBAAiB;GACjB,cAAc;GACjB,CACJ;EACD,eAAe;EACf,oBAAoB;EACpB,4BAA4B;EAC5B,SAAS,CACL,SACA,aACH;EACD,wBAAwB,CACpB,SACA,EACH;EACD,8BAA8B,CAC1B,SACA,EAAE,WAAW,MAAM,CACtB;EACD,qCAAqC,CACjC,SACA,6BACH;EACD,4BAA4B,CACxB,SACA;GACI,GAAG;GACH,aAAa;GAChB,CACJ;EACD,uCAAuC,CACnC,SACA;GACI,YAAY;GACZ,MAAM;GACT,CACJ;EACD,8BAA8B,CAC1B,SACA;GACI;GACA,QAAQ;IACJ;IACA;IACA;IACA,CACI,iBACA,eACH;IACD,CACI,kBACA,gBACH;IACD,CACI,kBACA,gBACH;IACD,CACI,gBACA,cACH;IACD,CACI,iBACA,eACH;IACD,CACI,eACA,aACH;IACD;IACH;GACD,YAAY;GACZ,iBAAiB;IACb;IACA;IACA;IACH;GACD,MAAM;GACT,CACJ;EACD,iCAAiC,CAC7B,SACA,6BACH;EACD,yCAAyC,CACrC,SACA,6BACH;EACD,2BAA2B,CACvB,SACA,6BACH;EACD,8BAA8B,CAC1B,SACA;GACI,GAAG;GACH,QAAQ;IACJ;IACA,CACI,eACA,OACH;IACD;IACA,CACI,oBACA,YACH;IACD;IACA,CACI,QACA,cACH;IACD;IACA,CACI,SACA,eACH;IACD;IACA,CACI,mBACA,WACH;IACJ;GACJ,CACJ;EACD,mCAAmC,CAC/B,SACA,6BACH;EACD,8BAA8B,CAC1B,SACA,6BACH;EACD,2BAA2B,CACvB,SACA,6BACH;EACD,kCAAkC,CAC9B,SACA;GACI,YAAY;GACZ,MAAM;GACT,CACJ;EACD,kCAAkC,CAC9B,SACA,6BACH;EACD,4CAA4C,CACxC,SACA,6BACH;EACD,gCAAgC;EAChC,gCAAgC;EAChC,0BAA0B;EAC1B,iBAAiB;EACjB,+BAA+B,CAC3B,SACA,EAAE,WAAW,MAAM,CACtB;EACD,+BAA+B,CAC3B,SACA;GACI,iBAAiB;IACb,YAAY;IACZ,UAAU;IACb;GACD,cAAc,EAAE,UAAU,GAAG;GAChC,CACJ;EACD,sBAAsB,CAClB,SACA,SACH;EACD,qBAAqB;GACjB;GACA;GACA,EAAE,iBAAiB,OAAO;GAC7B;EACD,+BAA+B,CAC3B,SACA,QACH;EACD,gBAAgB,CACZ,SACA,EACH;EACD,iBAAiB,CACb,QACA;GACI,MAAM;GACN,UAAU;GACb,CACJ;EACD,gCAAgC,CAC5B,SACA,EACI,WAAW;GACP,WAAW;GACX,aAAa;GAChB,EACJ,CACJ;EACD,yBAAyB;GACrB;GACA;GACA,EAAE,yBAAyB,OAAO;GACrC;EACD,uBAAuB;EACvB,8BAA8B,CAC1B,SACA;GACI,mBAAmB;IACf,eAAe;IACf,WAAW;IACd;GACD,mBAAmB;IACf,eAAe;IACf,WAAW;IACd;GACD,kBAAkB;IACd,eAAe;IACf,WAAW;IACd;GACD,eAAe;IACX,eAAe;IACf,WAAW;IACd;GACJ,CACJ;EACD,4BAA4B;GACxB;GACA;GACA,EAAE,WAAW,EAAE,KAAK,SAAS,EAAE;GAClC;EACD,yCAAyC;GACrC;GACA;IACI,WAAW;IACX,MAAM;KACF;KACA;KACA;KACH;IACD,MAAM;IACT;GACD;IACI,WAAW;IACX,MAAM;IACN,MAAM,CACF,SACA,WACH;IACJ;GACJ;EACD,cAAc,CACV,SACA,SACH;EACJ"}
package/dist/style.js CHANGED
@@ -1,5 +1,4 @@
1
1
  import format from "eslint-plugin-format";
2
-
3
2
  //#region src/style.ts
4
3
  function createPrettierCssConfig(parser) {
5
4
  return {
@@ -21,7 +20,7 @@ function createStyleFilesConfigs() {
21
20
  createPrettierCssConfig("scss")
22
21
  ];
23
22
  }
24
-
25
23
  //#endregion
26
24
  export { createStyleFilesConfigs };
25
+
27
26
  //# sourceMappingURL=style.js.map
package/dist/style.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"style.js","names":[],"sources":["../src/style.ts"],"sourcesContent":["import type { TypedFlatConfigItem } from '@antfu/eslint-config';\nimport format from 'eslint-plugin-format';\n\nfunction createPrettierCssConfig(parser: 'css' | 'sass' | 'scss'): TypedFlatConfigItem {\n return {\n files: [`**/*.${parser}`],\n languageOptions: { parser: format.parserPlain },\n plugins: { format },\n rules: {\n 'format/prettier': [\n 'error',\n {\n parser,\n printWidth: 120,\n singleQuote: true,\n tabWidth: 4,\n },\n ],\n },\n };\n}\n\nexport function createStyleFilesConfigs(): TypedFlatConfigItem[] {\n return [\n createPrettierCssConfig('css'),\n createPrettierCssConfig('sass'),\n createPrettierCssConfig('scss'),\n ];\n}\n"],"mappings":";;;AAGA,SAAS,wBAAwB,QAAsD;AACnF,QAAO;EACH,OAAO,CAAC,QAAQ,SAAS;EACzB,iBAAiB,EAAE,QAAQ,OAAO,aAAa;EAC/C,SAAS,EAAE,QAAQ;EACnB,OAAO,EACH,mBAAmB,CACf,SACA;GACI;GACA,YAAY;GACZ,aAAa;GACb,UAAU;GACb,CACJ,EACJ;EACJ;;AAGL,SAAgB,0BAAiD;AAC7D,QAAO;EACH,wBAAwB,MAAM;EAC9B,wBAAwB,OAAO;EAC/B,wBAAwB,OAAO;EAClC"}
1
+ {"version":3,"file":"style.js","names":[],"sources":["../src/style.ts"],"sourcesContent":["import type { TypedFlatConfigItem } from '@antfu/eslint-config';\nimport format from 'eslint-plugin-format';\n\nfunction createPrettierCssConfig(parser: 'css' | 'sass' | 'scss'): TypedFlatConfigItem {\n return {\n files: [`**/*.${parser}`],\n languageOptions: { parser: format.parserPlain },\n plugins: { format },\n rules: {\n 'format/prettier': [\n 'error',\n {\n parser,\n printWidth: 120,\n singleQuote: true,\n tabWidth: 4,\n },\n ],\n },\n };\n}\n\nexport function createStyleFilesConfigs(): TypedFlatConfigItem[] {\n return [\n createPrettierCssConfig('css'),\n createPrettierCssConfig('sass'),\n createPrettierCssConfig('scss'),\n ];\n}\n"],"mappings":";;AAGA,SAAS,wBAAwB,QAAsD;AACnF,QAAO;EACH,OAAO,CAAC,QAAQ,SAAS;EACzB,iBAAiB,EAAE,QAAQ,OAAO,aAAa;EAC/C,SAAS,EAAE,QAAQ;EACnB,OAAO,EACH,mBAAmB,CACf,SACA;GACI;GACA,YAAY;GACZ,aAAa;GACb,UAAU;GACb,CACJ,EACJ;EACJ;;AAGL,SAAgB,0BAAiD;AAC7D,QAAO;EACH,wBAAwB,MAAM;EAC9B,wBAAwB,OAAO;EAC/B,wBAAwB,OAAO;EAClC"}
package/dist/vue.js CHANGED
@@ -1,7 +1,6 @@
1
1
  import kikiutilsTailwindcss from "@kikiutils/eslint-plugin-tailwindcss";
2
2
  import kikiutilsEslintPluginVue from "@kikiutils/eslint-plugin-vue";
3
3
  import tailwindcss from "eslint-plugin-tailwindcss";
4
-
5
4
  //#region src/vue.ts
6
5
  function createVueConfig() {
7
6
  return {
@@ -57,7 +56,7 @@ function createVueConfig() {
57
56
  }
58
57
  };
59
58
  }
60
-
61
59
  //#endregion
62
60
  export { createVueConfig };
61
+
63
62
  //# sourceMappingURL=vue.js.map
package/dist/vue.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"vue.js","names":[],"sources":["../src/vue.ts"],"sourcesContent":["import type { TypedFlatConfigItem } from '@antfu/eslint-config';\n// @ts-expect-error No declare file.\nimport kikiutilsTailwindcss from '@kikiutils/eslint-plugin-tailwindcss';\n// @ts-expect-error Ignore this error.\nimport kikiutilsEslintPluginVue from '@kikiutils/eslint-plugin-vue';\n// @ts-expect-error No declare file.\nimport tailwindcss from 'eslint-plugin-tailwindcss';\n\nexport function createVueConfig(): TypedFlatConfigItem {\n return {\n files: ['**/*.vue'],\n plugins: {\n '@kikiutils/tailwindcss': kikiutilsTailwindcss,\n '@kikiutils/vue': kikiutilsEslintPluginVue,\n tailwindcss,\n },\n rules: {\n '@kikiutils/tailwindcss/classnames-order': 'error',\n '@kikiutils/vue/attributes-order': [\n 'error',\n { alphabetical: true },\n ],\n '@kikiutils/vue/no-extra-space-in-class': 'error',\n 'style/max-len': 'off',\n 'tailwindcss/classnames-order': 'off',\n 'tailwindcss/enforces-negative-arbitrary-values': 'error',\n 'tailwindcss/enforces-shorthand': 'error',\n 'tailwindcss/no-unnecessary-arbitrary-value': 'error',\n 'vue/attribute-hyphenation': 'error',\n 'vue/attributes-order': 'off',\n 'vue/block-order': [\n 'error',\n {\n order: [\n 'template',\n 'script',\n 'style',\n ],\n },\n ],\n 'vue/component-api-style': 'error',\n 'vue/define-emits-declaration': 'error',\n 'vue/define-props-declaration': 'error',\n 'vue/enforce-style-attribute': 'error',\n 'vue/html-closing-bracket-newline': 'error',\n 'vue/html-closing-bracket-spacing': 'error',\n 'vue/html-indent': [\n 'error',\n 4,\n ],\n 'vue/max-attributes-per-line': [\n 'error',\n {\n multiline: 1,\n singleline: 1,\n },\n ],\n 'vue/max-len': [\n 'warn',\n {\n code: 120,\n comments: 120,\n template: 120,\n },\n ],\n 'vue/no-dupe-keys': 'error',\n 'vue/no-lone-template': 'error',\n 'vue/no-multi-spaces': 'error',\n 'vue/no-multiple-objects-in-class': 'error',\n 'vue/no-root-v-if': 'error',\n 'vue/no-template-target-blank': 'error',\n 'vue/no-v-html': 'error',\n 'vue/prefer-define-options': 'error',\n 'vue/prefer-separate-static-class': 'error',\n 'vue/require-explicit-emits': 'error',\n 'vue/require-typed-ref': 'error',\n },\n };\n}\n"],"mappings":";;;;;AAQA,SAAgB,kBAAuC;AACnD,QAAO;EACH,OAAO,CAAC,WAAW;EACnB,SAAS;GACL,0BAA0B;GAC1B,kBAAkB;GAClB;GACH;EACD,OAAO;GACH,2CAA2C;GAC3C,mCAAmC,CAC/B,SACA,EAAE,cAAc,MAAM,CACzB;GACD,0CAA0C;GAC1C,iBAAiB;GACjB,gCAAgC;GAChC,kDAAkD;GAClD,kCAAkC;GAClC,8CAA8C;GAC9C,6BAA6B;GAC7B,wBAAwB;GACxB,mBAAmB,CACf,SACA,EACI,OAAO;IACH;IACA;IACA;IACH,EACJ,CACJ;GACD,2BAA2B;GAC3B,gCAAgC;GAChC,gCAAgC;GAChC,+BAA+B;GAC/B,oCAAoC;GACpC,oCAAoC;GACpC,mBAAmB,CACf,SACA,EACH;GACD,+BAA+B,CAC3B,SACA;IACI,WAAW;IACX,YAAY;IACf,CACJ;GACD,eAAe,CACX,QACA;IACI,MAAM;IACN,UAAU;IACV,UAAU;IACb,CACJ;GACD,oBAAoB;GACpB,wBAAwB;GACxB,uBAAuB;GACvB,oCAAoC;GACpC,oBAAoB;GACpB,gCAAgC;GAChC,iBAAiB;GACjB,6BAA6B;GAC7B,oCAAoC;GACpC,8BAA8B;GAC9B,yBAAyB;GAC5B;EACJ"}
1
+ {"version":3,"file":"vue.js","names":[],"sources":["../src/vue.ts"],"sourcesContent":["import type { TypedFlatConfigItem } from '@antfu/eslint-config';\n// @ts-expect-error No declare file.\nimport kikiutilsTailwindcss from '@kikiutils/eslint-plugin-tailwindcss';\n// @ts-expect-error Ignore this error.\nimport kikiutilsEslintPluginVue from '@kikiutils/eslint-plugin-vue';\n// @ts-expect-error No declare file.\nimport tailwindcss from 'eslint-plugin-tailwindcss';\n\nexport function createVueConfig(): TypedFlatConfigItem {\n return {\n files: ['**/*.vue'],\n plugins: {\n '@kikiutils/tailwindcss': kikiutilsTailwindcss,\n '@kikiutils/vue': kikiutilsEslintPluginVue,\n tailwindcss,\n },\n rules: {\n '@kikiutils/tailwindcss/classnames-order': 'error',\n '@kikiutils/vue/attributes-order': [\n 'error',\n { alphabetical: true },\n ],\n '@kikiutils/vue/no-extra-space-in-class': 'error',\n 'style/max-len': 'off',\n 'tailwindcss/classnames-order': 'off',\n 'tailwindcss/enforces-negative-arbitrary-values': 'error',\n 'tailwindcss/enforces-shorthand': 'error',\n 'tailwindcss/no-unnecessary-arbitrary-value': 'error',\n 'vue/attribute-hyphenation': 'error',\n 'vue/attributes-order': 'off',\n 'vue/block-order': [\n 'error',\n {\n order: [\n 'template',\n 'script',\n 'style',\n ],\n },\n ],\n 'vue/component-api-style': 'error',\n 'vue/define-emits-declaration': 'error',\n 'vue/define-props-declaration': 'error',\n 'vue/enforce-style-attribute': 'error',\n 'vue/html-closing-bracket-newline': 'error',\n 'vue/html-closing-bracket-spacing': 'error',\n 'vue/html-indent': [\n 'error',\n 4,\n ],\n 'vue/max-attributes-per-line': [\n 'error',\n {\n multiline: 1,\n singleline: 1,\n },\n ],\n 'vue/max-len': [\n 'warn',\n {\n code: 120,\n comments: 120,\n template: 120,\n },\n ],\n 'vue/no-dupe-keys': 'error',\n 'vue/no-lone-template': 'error',\n 'vue/no-multi-spaces': 'error',\n 'vue/no-multiple-objects-in-class': 'error',\n 'vue/no-root-v-if': 'error',\n 'vue/no-template-target-blank': 'error',\n 'vue/no-v-html': 'error',\n 'vue/prefer-define-options': 'error',\n 'vue/prefer-separate-static-class': 'error',\n 'vue/require-explicit-emits': 'error',\n 'vue/require-typed-ref': 'error',\n },\n };\n}\n"],"mappings":";;;;AAQA,SAAgB,kBAAuC;AACnD,QAAO;EACH,OAAO,CAAC,WAAW;EACnB,SAAS;GACL,0BAA0B;GAC1B,kBAAkB;GAClB;GACH;EACD,OAAO;GACH,2CAA2C;GAC3C,mCAAmC,CAC/B,SACA,EAAE,cAAc,MAAM,CACzB;GACD,0CAA0C;GAC1C,iBAAiB;GACjB,gCAAgC;GAChC,kDAAkD;GAClD,kCAAkC;GAClC,8CAA8C;GAC9C,6BAA6B;GAC7B,wBAAwB;GACxB,mBAAmB,CACf,SACA,EACI,OAAO;IACH;IACA;IACA;IACH,EACJ,CACJ;GACD,2BAA2B;GAC3B,gCAAgC;GAChC,gCAAgC;GAChC,+BAA+B;GAC/B,oCAAoC;GACpC,oCAAoC;GACpC,mBAAmB,CACf,SACA,EACH;GACD,+BAA+B,CAC3B,SACA;IACI,WAAW;IACX,YAAY;IACf,CACJ;GACD,eAAe,CACX,QACA;IACI,MAAM;IACN,UAAU;IACV,UAAU;IACb,CACJ;GACD,oBAAoB;GACpB,wBAAwB;GACxB,uBAAuB;GACvB,oCAAoC;GACpC,oBAAoB;GACpB,gCAAgC;GAChC,iBAAiB;GACjB,6BAA6B;GAC7B,oCAAoC;GACpC,8BAA8B;GAC9B,yBAAyB;GAC5B;EACJ"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@kikiutils/eslint-config",
3
3
  "type": "module",
4
- "version": "6.0.0",
4
+ "version": "7.0.0",
5
5
  "description": "Using antfu/eslint-config as a base for eslint-config, slightly modified the settings and added additional plugins, mainly for my own use.",
6
6
  "author": "kiki-kanri",
7
7
  "license": "MIT",
@@ -25,21 +25,20 @@
25
25
  "scripts": {
26
26
  "build": "tsdown",
27
27
  "bumplog": "changelogen --bump --hideAuthorEmail",
28
- "depcheck": "depcheck",
28
+ "knip:deps": "knip --dependencies",
29
+ "knip:exports": "knip --exports",
29
30
  "lint": "eslint --max-warnings 0",
30
31
  "lint:fix": "eslint --fix --max-warnings 0",
31
32
  "prepack": "pnpm run build",
32
33
  "release": "pnpm run lint && pnpm run typecheck && pnpm run test && pnpm run build && changelogen --hideAuthorEmail --push --release && npm publish",
33
34
  "test": "vitest run --coverage",
34
35
  "test:watch": "vitest watch --coverage",
35
- "typecheck": "tsc -b --noEmit",
36
- "unused-exports": "ts-unused-exports ./tsconfig.json"
36
+ "typecheck": "tsc -b --noEmit"
37
37
  },
38
38
  "peerDependencies": {
39
39
  "@kikiutils/eslint-plugin-tailwindcss": "^3.19.0",
40
40
  "@kikiutils/eslint-plugin-vue": "^10.2.2",
41
41
  "eslint": ">= 9.0.0",
42
- "eslint-flat-config-utils": ">= 2.0.0",
43
42
  "eslint-plugin-format": ">= 1.0.0",
44
43
  "eslint-plugin-tailwindcss": "^3.18.2"
45
44
  },
@@ -50,7 +49,7 @@
50
49
  "@kikiutils/eslint-plugin-vue": {
51
50
  "optional": true
52
51
  },
53
- "eslint-flat-config-utils": {
52
+ "eslint": {
54
53
  "optional": true
55
54
  },
56
55
  "eslint-plugin-format": {
@@ -61,23 +60,21 @@
61
60
  }
62
61
  },
63
62
  "dependencies": {
64
- "@antfu/eslint-config": "^7.6.1",
63
+ "@antfu/eslint-config": "^7.7.0",
65
64
  "eslint-plugin-promise": "^7.2.1"
66
65
  },
67
66
  "devDependencies": {
68
67
  "@kikiutils/eslint-plugin-tailwindcss": "^3.19.0",
69
68
  "@kikiutils/eslint-plugin-vue": "^10.2.2",
70
69
  "@kikiutils/tsconfigs": "^5.1.0",
71
- "@types/node": "^25.3.3",
70
+ "@types/node": "^25.3.5",
72
71
  "@vitest/coverage-v8": "^4.0.18",
73
72
  "changelogen": "^0.6.2",
74
- "depcheck": "^1.4.7",
75
- "eslint-flat-config-utils": "^3.0.1",
76
73
  "eslint-plugin-format": "^2.0.1",
77
74
  "eslint-plugin-tailwindcss": "^3.18.2",
75
+ "knip": "^5.86.0",
78
76
  "publint": "^0.3.18",
79
- "ts-unused-exports": "^11.0.1",
80
- "tsdown": "^0.20.3",
77
+ "tsdown": "^0.21.0",
81
78
  "typescript": "^5.9.3",
82
79
  "unplugin-unused": "^0.5.7",
83
80
  "vitest": "^4.0.18"
package/src/base.ts CHANGED
@@ -1,4 +1,7 @@
1
- import type { TypedFlatConfigItem } from '@antfu/eslint-config';
1
+ import type {
2
+ Rules,
3
+ TypedFlatConfigItem,
4
+ } from '@antfu/eslint-config';
2
5
  // @ts-expect-error No declare file.
3
6
  import promise from 'eslint-plugin-promise';
4
7
 
@@ -9,281 +12,75 @@ const basePerfectionistSortOptions = {
9
12
 
10
13
  export function createBaseConfigs(environment: 'bun' | 'node' = 'node'): TypedFlatConfigItem[] {
11
14
  return [
15
+ // All files
12
16
  {
13
- files: ['**/*.{cjs,js,mjs,ts,tsx}'],
14
17
  rules: {
15
- 'node/prefer-global/process': [
18
+ 'e18e/ban-dependencies': [
16
19
  'error',
17
- 'always',
20
+ { allowed: ['axios'] },
18
21
  ],
22
+ 'e18e/prefer-static-regex': ['off'],
19
23
  },
20
24
  },
25
+ // JavaScript
21
26
  {
22
- files: ['**/*.{cjs,js,mjs,ts,tsx,vue}'],
27
+ files: ['**/*.{cjs,js,mjs}'],
23
28
  plugins: { promise },
24
29
  rules: {
25
- 'antfu/consistent-list-newline': [
26
- 'error',
27
- {
28
- ArrayExpression: false,
29
- ArrayPattern: false,
30
- },
31
- ],
32
- 'antfu/curly': 'off',
33
- 'antfu/if-newline': 'off',
34
- 'antfu/no-top-level-await': 'off',
35
- 'curly': [
36
- 'error',
37
- 'multi-line',
38
- ],
39
- 'max-classes-per-file': [
40
- 'error',
41
- 1,
42
- ],
43
- 'no-promise-executor-return': [
44
- 'error',
45
- { allowVoid: true },
46
- ],
47
- 'perfectionist/sort-array-includes': [
48
- 'error',
49
- basePerfectionistSortOptions,
50
- ],
51
- 'perfectionist/sort-enums': [
52
- 'error',
53
- {
54
- ...basePerfectionistSortOptions,
55
- sortByValue: 'never',
56
- },
57
- ],
58
- 'perfectionist/sort-heritage-clauses': [
59
- 'error',
60
- {
61
- ignoreCase: false,
62
- type: 'natural',
63
- },
64
- ],
65
- 'perfectionist/sort-imports': [
66
- 'error',
67
- {
68
- environment,
69
- groups: [
70
- 'side-effect',
71
- 'side-effect-style',
72
- 'style',
73
- [
74
- 'value-builtin',
75
- 'type-builtin',
76
- ],
77
- [
78
- 'value-external',
79
- 'type-external',
80
- ],
81
- [
82
- 'value-internal',
83
- 'type-internal',
84
- ],
85
- [
86
- 'value-parent',
87
- 'type-parent',
88
- ],
89
- [
90
- 'value-sibling',
91
- 'type-sibling',
92
- ],
93
- [
94
- 'value-index',
95
- 'type-index',
96
- ],
97
- 'unknown',
98
- ],
99
- ignoreCase: false,
100
- internalPattern: [
101
- '^#.*',
102
- '^@/.*',
103
- '^~/.*',
104
- ],
105
- type: 'natural',
106
- },
107
- ],
108
- 'perfectionist/sort-interfaces': [
109
- 'error',
110
- basePerfectionistSortOptions,
111
- ],
112
- 'perfectionist/sort-intersection-types': [
113
- 'error',
114
- basePerfectionistSortOptions,
115
- ],
116
- 'perfectionist/sort-maps': [
117
- 'error',
118
- basePerfectionistSortOptions,
119
- ],
120
- 'perfectionist/sort-modules': [
121
- 'error',
122
- {
123
- ...basePerfectionistSortOptions,
124
- groups: [
125
- 'declare-type',
126
- [
127
- 'export-type',
128
- 'type',
129
- ],
130
- 'declare-interface',
131
- [
132
- 'export-interface',
133
- 'interface',
134
- ],
135
- 'declare-enum',
136
- [
137
- 'enum',
138
- 'export-enum',
139
- ],
140
- 'declare-class',
141
- [
142
- 'class',
143
- 'export-class',
144
- ],
145
- 'declare-function',
146
- [
147
- 'export-function',
148
- 'function',
149
- ],
150
- ],
151
- },
152
- ],
153
- 'perfectionist/sort-object-types': [
154
- 'error',
155
- basePerfectionistSortOptions,
156
- ],
157
- 'perfectionist/sort-objects': [
158
- 'error',
159
- basePerfectionistSortOptions,
160
- ],
161
- 'perfectionist/sort-sets': [
162
- 'error',
163
- basePerfectionistSortOptions,
164
- ],
165
- 'perfectionist/sort-switch-case': [
166
- 'error',
167
- {
168
- ignoreCase: false,
169
- type: 'natural',
170
- },
171
- ],
172
- 'perfectionist/sort-union-types': [
173
- 'error',
174
- basePerfectionistSortOptions,
175
- ],
176
- 'perfectionist/sort-variable-declarations': [
177
- 'error',
178
- basePerfectionistSortOptions,
179
- ],
180
- 'promise/no-multiple-resolved': 'error',
181
- 'promise/no-return-in-finally': 'error',
182
- 'promise/no-return-wrap': 'error',
183
- 'require-await': 'error',
184
- 'style/array-bracket-newline': [
185
- 'error',
186
- { multiline: true },
187
- ],
188
- 'style/array-element-newline': [
189
- 'error',
190
- {
191
- ArrayExpression: {
192
- consistent: true,
193
- minItems: 2,
194
- },
195
- ArrayPattern: { minItems: 3 },
196
- },
197
- ],
198
- 'style/arrow-parens': [
30
+ ...createBaseRules(environment),
31
+ 'node/prefer-global/process': [
199
32
  'error',
200
33
  'always',
201
34
  ],
202
- 'style/brace-style': [
203
- 'error',
204
- '1tbs',
205
- { allowSingleLine: false },
206
- ],
207
- 'style/function-call-spacing': [
35
+ },
36
+ },
37
+ // TypeScript
38
+ {
39
+ files: ['**/*.{ts,tsx}'],
40
+ plugins: { promise },
41
+ rules: {
42
+ ...createBaseRules(environment),
43
+ 'node/prefer-global/process': [
208
44
  'error',
209
- 'never',
45
+ 'always',
210
46
  ],
211
- 'style/indent': [
47
+ 'ts/consistent-generic-constructors': [
212
48
  'error',
213
- 4,
214
- ],
215
- 'style/max-len': [
216
- 'warn',
217
- {
218
- code: 120,
219
- comments: 120,
220
- },
49
+ 'constructor',
221
50
  ],
222
- 'style/member-delimiter-style': [
51
+ 'ts/no-redeclare': 'off',
52
+ },
53
+ },
54
+ // VsCode jsonc
55
+ {
56
+ files: ['**/.vscode/*.json'],
57
+ rules: {
58
+ 'jsonc/sort-array-values': [
223
59
  'error',
224
60
  {
225
- multiline: {
226
- delimiter: 'semi',
227
- requireLast: true,
61
+ order: {
62
+ natural: true,
63
+ type: 'asc',
228
64
  },
65
+ pathPattern: '^.*$',
229
66
  },
230
67
  ],
231
- 'style/no-extra-parens': [
232
- 'error',
233
- 'all',
234
- { nestedBinaryExpressions: false },
235
- ],
236
- 'style/no-extra-semi': 'error',
237
- 'style/object-curly-newline': [
68
+ 'jsonc/sort-keys': [
238
69
  'error',
70
+ 'asc',
239
71
  {
240
- ExportDeclaration: {
241
- minProperties: 2,
242
- multiline: true,
243
- },
244
- ImportDeclaration: {
245
- minProperties: 2,
246
- multiline: true,
247
- },
248
- ObjectExpression: {
249
- minProperties: 2,
250
- multiline: true,
251
- },
252
- ObjectPattern: {
253
- minProperties: 3,
254
- multiline: true,
255
- },
72
+ caseSensitive: true,
73
+ natural: true,
256
74
  },
257
75
  ],
258
- 'style/operator-linebreak': [
259
- 'error',
260
- 'before',
261
- { overrides: { '=': 'after' } },
262
- ],
263
- 'style/padding-line-between-statements': [
264
- 'error',
265
- {
266
- blankLine: 'always',
267
- next: [
268
- 'class',
269
- 'enum',
270
- 'function',
271
- ],
272
- prev: '*',
273
- },
274
- {
275
- blankLine: 'always',
276
- next: '*',
277
- prev: [
278
- 'class',
279
- 'function',
280
- ],
281
- },
282
- ],
283
- 'style/semi': [
284
- 'error',
285
- 'always',
286
- ],
76
+ },
77
+ },
78
+ // Vue
79
+ {
80
+ files: ['**/*.{vue}'],
81
+ plugins: { promise },
82
+ rules: {
83
+ ...createBaseRules(environment),
287
84
  'ts/consistent-generic-constructors': [
288
85
  'error',
289
86
  'constructor',
@@ -293,3 +90,270 @@ export function createBaseConfigs(environment: 'bun' | 'node' = 'node'): TypedFl
293
90
  },
294
91
  ];
295
92
  }
93
+
94
+ function createBaseRules(environment: 'bun' | 'node' = 'node'): Rules {
95
+ return {
96
+ 'antfu/consistent-list-newline': [
97
+ 'error',
98
+ {
99
+ ArrayExpression: false,
100
+ ArrayPattern: false,
101
+ },
102
+ ],
103
+ 'antfu/curly': 'off',
104
+ 'antfu/if-newline': 'off',
105
+ 'antfu/no-top-level-await': 'off',
106
+ 'curly': [
107
+ 'error',
108
+ 'multi-line',
109
+ ],
110
+ 'max-classes-per-file': [
111
+ 'error',
112
+ 1,
113
+ ],
114
+ 'no-promise-executor-return': [
115
+ 'error',
116
+ { allowVoid: true },
117
+ ],
118
+ 'perfectionist/sort-array-includes': [
119
+ 'error',
120
+ basePerfectionistSortOptions,
121
+ ],
122
+ 'perfectionist/sort-enums': [
123
+ 'error',
124
+ {
125
+ ...basePerfectionistSortOptions,
126
+ sortByValue: 'never',
127
+ },
128
+ ],
129
+ 'perfectionist/sort-heritage-clauses': [
130
+ 'error',
131
+ {
132
+ ignoreCase: false,
133
+ type: 'natural',
134
+ },
135
+ ],
136
+ 'perfectionist/sort-imports': [
137
+ 'error',
138
+ {
139
+ environment,
140
+ groups: [
141
+ 'side-effect',
142
+ 'side-effect-style',
143
+ 'style',
144
+ [
145
+ 'value-builtin',
146
+ 'type-builtin',
147
+ ],
148
+ [
149
+ 'value-external',
150
+ 'type-external',
151
+ ],
152
+ [
153
+ 'value-internal',
154
+ 'type-internal',
155
+ ],
156
+ [
157
+ 'value-parent',
158
+ 'type-parent',
159
+ ],
160
+ [
161
+ 'value-sibling',
162
+ 'type-sibling',
163
+ ],
164
+ [
165
+ 'value-index',
166
+ 'type-index',
167
+ ],
168
+ 'unknown',
169
+ ],
170
+ ignoreCase: false,
171
+ internalPattern: [
172
+ '^#.*',
173
+ '^@/.*',
174
+ '^~/.*',
175
+ ],
176
+ type: 'natural',
177
+ },
178
+ ],
179
+ 'perfectionist/sort-interfaces': [
180
+ 'error',
181
+ basePerfectionistSortOptions,
182
+ ],
183
+ 'perfectionist/sort-intersection-types': [
184
+ 'error',
185
+ basePerfectionistSortOptions,
186
+ ],
187
+ 'perfectionist/sort-maps': [
188
+ 'error',
189
+ basePerfectionistSortOptions,
190
+ ],
191
+ 'perfectionist/sort-modules': [
192
+ 'error',
193
+ {
194
+ ...basePerfectionistSortOptions,
195
+ groups: [
196
+ 'declare-type',
197
+ [
198
+ 'export-type',
199
+ 'type',
200
+ ],
201
+ 'declare-interface',
202
+ [
203
+ 'export-interface',
204
+ 'interface',
205
+ ],
206
+ 'declare-enum',
207
+ [
208
+ 'enum',
209
+ 'export-enum',
210
+ ],
211
+ 'declare-class',
212
+ [
213
+ 'class',
214
+ 'export-class',
215
+ ],
216
+ 'declare-function',
217
+ [
218
+ 'export-function',
219
+ 'function',
220
+ ],
221
+ ],
222
+ },
223
+ ],
224
+ 'perfectionist/sort-object-types': [
225
+ 'error',
226
+ basePerfectionistSortOptions,
227
+ ],
228
+ 'perfectionist/sort-objects': [
229
+ 'error',
230
+ basePerfectionistSortOptions,
231
+ ],
232
+ 'perfectionist/sort-sets': [
233
+ 'error',
234
+ basePerfectionistSortOptions,
235
+ ],
236
+ 'perfectionist/sort-switch-case': [
237
+ 'error',
238
+ {
239
+ ignoreCase: false,
240
+ type: 'natural',
241
+ },
242
+ ],
243
+ 'perfectionist/sort-union-types': [
244
+ 'error',
245
+ basePerfectionistSortOptions,
246
+ ],
247
+ 'perfectionist/sort-variable-declarations': [
248
+ 'error',
249
+ basePerfectionistSortOptions,
250
+ ],
251
+ 'promise/no-multiple-resolved': 'error',
252
+ 'promise/no-return-in-finally': 'error',
253
+ 'promise/no-return-wrap': 'error',
254
+ 'require-await': 'error',
255
+ 'style/array-bracket-newline': [
256
+ 'error',
257
+ { multiline: true },
258
+ ],
259
+ 'style/array-element-newline': [
260
+ 'error',
261
+ {
262
+ ArrayExpression: {
263
+ consistent: true,
264
+ minItems: 2,
265
+ },
266
+ ArrayPattern: { minItems: 3 },
267
+ },
268
+ ],
269
+ 'style/arrow-parens': [
270
+ 'error',
271
+ 'always',
272
+ ],
273
+ 'style/brace-style': [
274
+ 'error',
275
+ '1tbs',
276
+ { allowSingleLine: false },
277
+ ],
278
+ 'style/function-call-spacing': [
279
+ 'error',
280
+ 'never',
281
+ ],
282
+ 'style/indent': [
283
+ 'error',
284
+ 4,
285
+ ],
286
+ 'style/max-len': [
287
+ 'warn',
288
+ {
289
+ code: 120,
290
+ comments: 120,
291
+ },
292
+ ],
293
+ 'style/member-delimiter-style': [
294
+ 'error',
295
+ {
296
+ multiline: {
297
+ delimiter: 'semi',
298
+ requireLast: true,
299
+ },
300
+ },
301
+ ],
302
+ 'style/no-extra-parens': [
303
+ 'error',
304
+ 'all',
305
+ { nestedBinaryExpressions: false },
306
+ ],
307
+ 'style/no-extra-semi': 'error',
308
+ 'style/object-curly-newline': [
309
+ 'error',
310
+ {
311
+ ExportDeclaration: {
312
+ minProperties: 2,
313
+ multiline: true,
314
+ },
315
+ ImportDeclaration: {
316
+ minProperties: 2,
317
+ multiline: true,
318
+ },
319
+ ObjectExpression: {
320
+ minProperties: 2,
321
+ multiline: true,
322
+ },
323
+ ObjectPattern: {
324
+ minProperties: 3,
325
+ multiline: true,
326
+ },
327
+ },
328
+ ],
329
+ 'style/operator-linebreak': [
330
+ 'error',
331
+ 'before',
332
+ { overrides: { '=': 'after' } },
333
+ ],
334
+ 'style/padding-line-between-statements': [
335
+ 'error',
336
+ {
337
+ blankLine: 'always',
338
+ next: [
339
+ 'class',
340
+ 'enum',
341
+ 'function',
342
+ ],
343
+ prev: '*',
344
+ },
345
+ {
346
+ blankLine: 'always',
347
+ next: '*',
348
+ prev: [
349
+ 'class',
350
+ 'function',
351
+ ],
352
+ },
353
+ ],
354
+ 'style/semi': [
355
+ 'error',
356
+ 'always',
357
+ ],
358
+ };
359
+ }
package/dist/json.d.ts DELETED
@@ -1,7 +0,0 @@
1
- import { TypedFlatConfigItem } from "@antfu/eslint-config";
2
-
3
- //#region src/json.d.ts
4
- declare function createVsCodeJsonConfigs(): TypedFlatConfigItem[];
5
- //#endregion
6
- export { createVsCodeJsonConfigs };
7
- //# sourceMappingURL=json.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"json.d.ts","names":[],"sources":["../src/json.ts"],"mappings":";;;iBAEgB,uBAAA,CAAA,GAA2B,mBAAA"}
package/dist/json.js DELETED
@@ -1,27 +0,0 @@
1
- //#region src/json.ts
2
- function createVsCodeJsonConfigs() {
3
- return [{
4
- files: ["**/.vscode/*.json"],
5
- rules: {
6
- "jsonc/sort-array-values": ["error", {
7
- order: {
8
- natural: true,
9
- type: "asc"
10
- },
11
- pathPattern: "^.*$"
12
- }],
13
- "jsonc/sort-keys": [
14
- "error",
15
- "asc",
16
- {
17
- caseSensitive: true,
18
- natural: true
19
- }
20
- ]
21
- }
22
- }];
23
- }
24
-
25
- //#endregion
26
- export { createVsCodeJsonConfigs };
27
- //# sourceMappingURL=json.js.map
package/dist/json.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"json.js","names":[],"sources":["../src/json.ts"],"sourcesContent":["import type { TypedFlatConfigItem } from '@antfu/eslint-config';\n\nexport function createVsCodeJsonConfigs(): TypedFlatConfigItem[] {\n return [\n {\n files: ['**/.vscode/*.json'],\n rules: {\n 'jsonc/sort-array-values': [\n 'error',\n {\n order: {\n natural: true,\n type: 'asc',\n },\n pathPattern: '^.*$',\n },\n ],\n 'jsonc/sort-keys': [\n 'error',\n 'asc',\n {\n caseSensitive: true,\n natural: true,\n },\n ],\n },\n },\n ];\n}\n"],"mappings":";AAEA,SAAgB,0BAAiD;AAC7D,QAAO,CACH;EACI,OAAO,CAAC,oBAAoB;EAC5B,OAAO;GACH,2BAA2B,CACvB,SACA;IACI,OAAO;KACH,SAAS;KACT,MAAM;KACT;IACD,aAAa;IAChB,CACJ;GACD,mBAAmB;IACf;IACA;IACA;KACI,eAAe;KACf,SAAS;KACZ;IACJ;GACJ;EACJ,CACJ"}
package/src/json.ts DELETED
@@ -1,29 +0,0 @@
1
- import type { TypedFlatConfigItem } from '@antfu/eslint-config';
2
-
3
- export function createVsCodeJsonConfigs(): TypedFlatConfigItem[] {
4
- return [
5
- {
6
- files: ['**/.vscode/*.json'],
7
- rules: {
8
- 'jsonc/sort-array-values': [
9
- 'error',
10
- {
11
- order: {
12
- natural: true,
13
- type: 'asc',
14
- },
15
- pathPattern: '^.*$',
16
- },
17
- ],
18
- 'jsonc/sort-keys': [
19
- 'error',
20
- 'asc',
21
- {
22
- caseSensitive: true,
23
- natural: true,
24
- },
25
- ],
26
- },
27
- },
28
- ];
29
- }