@tcy/eslint-rules 1.3.3 → 1.4.2

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,6 +1,6 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
- <coverage generated="1776157810529" clover="3.2.0">
3
- <project timestamp="1776157810529" name="All files">
2
+ <coverage generated="1776171353571" clover="3.2.0">
3
+ <project timestamp="1776171353571" name="All files">
4
4
  <metrics statements="242" coveredstatements="2" conditionals="201" coveredconditionals="0" methods="49" coveredmethods="1" elements="492" coveredelements="3" complexity="0" loc="242" ncloc="242" packages="1" files="10" classes="10"/>
5
5
  <file name="array-elements-per-line.js" path="/home/runner/work/eslint-rules/eslint-rules/src/array-elements-per-line.js">
6
6
  <metrics statements="25" coveredstatements="0" conditionals="17" coveredconditionals="0" methods="4" coveredmethods="0"/>
@@ -253,7 +253,7 @@ line when first element is on a new line.`,
253
253
  <div class='footer quiet pad2 space-top1 center small'>
254
254
  Code coverage generated by
255
255
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
256
- at 2026-04-14T09:10:10.519Z
256
+ at 2026-04-14T12:55:53.555Z
257
257
  </div>
258
258
  <script src="prettify.js"></script>
259
259
  <script>
@@ -301,7 +301,7 @@ export default {
301
301
  <div class='footer quiet pad2 space-top1 center small'>
302
302
  Code coverage generated by
303
303
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
304
- at 2026-04-14T09:10:10.519Z
304
+ at 2026-04-14T12:55:53.555Z
305
305
  </div>
306
306
  <script src="prettify.js"></script>
307
307
  <script>
@@ -562,7 +562,7 @@ export default {
562
562
  <div class='footer quiet pad2 space-top1 center small'>
563
563
  Code coverage generated by
564
564
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
565
- at 2026-04-14T09:10:10.519Z
565
+ at 2026-04-14T12:55:53.555Z
566
566
  </div>
567
567
  <script src="prettify.js"></script>
568
568
  <script>
@@ -259,7 +259,7 @@
259
259
  <div class='footer quiet pad2 space-top1 center small'>
260
260
  Code coverage generated by
261
261
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
262
- at 2026-04-14T09:10:10.519Z
262
+ at 2026-04-14T12:55:53.555Z
263
263
  </div>
264
264
  <script src="prettify.js"></script>
265
265
  <script>
@@ -376,7 +376,7 @@
376
376
  <div class='footer quiet pad2 space-top1 center small'>
377
377
  Code coverage generated by
378
378
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
379
- at 2026-04-14T09:10:10.519Z
379
+ at 2026-04-14T12:55:53.555Z
380
380
  </div>
381
381
  <script src="prettify.js"></script>
382
382
  <script>
@@ -236,7 +236,7 @@
236
236
  <div class='footer quiet pad2 space-top1 center small'>
237
237
  Code coverage generated by
238
238
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
239
- at 2026-04-14T09:10:10.519Z
239
+ at 2026-04-14T12:55:53.555Z
240
240
  </div>
241
241
  <script src="prettify.js"></script>
242
242
  <script>
@@ -86,7 +86,35 @@
86
86
  <a name='L21'></a><a href='#L21'>21</a>
87
87
  <a name='L22'></a><a href='#L22'>22</a>
88
88
  <a name='L23'></a><a href='#L23'>23</a>
89
- <a name='L24'></a><a href='#L24'>24</a></td><td class="line-coverage quiet"><span class="cline-any cline-neutral">&nbsp;</span>
89
+ <a name='L24'></a><a href='#L24'>24</a>
90
+ <a name='L25'></a><a href='#L25'>25</a>
91
+ <a name='L26'></a><a href='#L26'>26</a>
92
+ <a name='L27'></a><a href='#L27'>27</a>
93
+ <a name='L28'></a><a href='#L28'>28</a>
94
+ <a name='L29'></a><a href='#L29'>29</a>
95
+ <a name='L30'></a><a href='#L30'>30</a>
96
+ <a name='L31'></a><a href='#L31'>31</a>
97
+ <a name='L32'></a><a href='#L32'>32</a>
98
+ <a name='L33'></a><a href='#L33'>33</a>
99
+ <a name='L34'></a><a href='#L34'>34</a>
100
+ <a name='L35'></a><a href='#L35'>35</a>
101
+ <a name='L36'></a><a href='#L36'>36</a>
102
+ <a name='L37'></a><a href='#L37'>37</a>
103
+ <a name='L38'></a><a href='#L38'>38</a></td><td class="line-coverage quiet"><span class="cline-any cline-neutral">&nbsp;</span>
104
+ <span class="cline-any cline-neutral">&nbsp;</span>
105
+ <span class="cline-any cline-neutral">&nbsp;</span>
106
+ <span class="cline-any cline-neutral">&nbsp;</span>
107
+ <span class="cline-any cline-neutral">&nbsp;</span>
108
+ <span class="cline-any cline-neutral">&nbsp;</span>
109
+ <span class="cline-any cline-neutral">&nbsp;</span>
110
+ <span class="cline-any cline-neutral">&nbsp;</span>
111
+ <span class="cline-any cline-neutral">&nbsp;</span>
112
+ <span class="cline-any cline-neutral">&nbsp;</span>
113
+ <span class="cline-any cline-neutral">&nbsp;</span>
114
+ <span class="cline-any cline-neutral">&nbsp;</span>
115
+ <span class="cline-any cline-neutral">&nbsp;</span>
116
+ <span class="cline-any cline-neutral">&nbsp;</span>
117
+ <span class="cline-any cline-neutral">&nbsp;</span>
90
118
  <span class="cline-any cline-neutral">&nbsp;</span>
91
119
  <span class="cline-any cline-neutral">&nbsp;</span>
92
120
  <span class="cline-any cline-neutral">&nbsp;</span>
@@ -120,16 +148,30 @@ import vuejsDefineComponent from './vuejs-define-component.js'
120
148
  import vuejsDefineWorkspace from './vuejs-define-workspace.js'
121
149
  &nbsp;
122
150
  export default {
151
+ plugins: {
152
+ tcy: {
153
+ rules: {
154
+ 'import-specifiers-per-line': importSpecifiersPerLineRule,
155
+ 'array-elements-per-line': arrayElementsPerLineRule,
156
+ 'export-specifiers-per-line': exportSpecifiersPerLineRule,
157
+ 'jsx-expression-string-literals': jsxExpressionStringLiterals,
158
+ 'enforce-tailwind-important': enforceTailwindImportant,
159
+ 'v-model-name-match': vModelNameMatch,
160
+ 'decorator-type-enforcement': decoratorTypeEnforcement,
161
+ 'vuejs-define-component': vuejsDefineComponent,
162
+ 'vuejs-define-workspace': vuejsDefineWorkspace,
163
+ }
164
+ }
165
+ },
123
166
  rules: {
124
- 'import-specifiers-per-line': importSpecifiersPerLineRule,
125
- 'array-elements-per-line': arrayElementsPerLineRule,
126
- 'export-specifiers-per-line': exportSpecifiersPerLineRule,
127
- 'jsx-expression-string-literals': jsxExpressionStringLiterals,
128
- 'enforce-tailwind-important': enforceTailwindImportant,
129
- 'v-model-name-match': vModelNameMatch,
130
- 'decorator-type-enforcement': decoratorTypeEnforcement,
131
- 'vuejs-define-component': vuejsDefineComponent,
132
- 'vuejs-define-workspace': vuejsDefineWorkspace,
167
+ 'tcy/import-specifiers-per-line': ['error', { maxSpecifiers: 4 }],
168
+ 'tcy/export-specifiers-per-line': 'error',
169
+ 'tcy/array-elements-per-line': 'error',
170
+ 'tcy/jsx-expression-string-literals': 'error',
171
+ 'tcy/enforce-tailwind-important': 'error',
172
+ 'tcy/v-model-name-match': 'error',
173
+ 'tcy/vuejs-define-component': 'error',
174
+ 'tcy/vuejs-define-workspace': 'error',
133
175
  },
134
176
  };
135
177
  &nbsp;</pre></td></tr></table></pre>
@@ -139,7 +181,7 @@ export default {
139
181
  <div class='footer quiet pad2 space-top1 center small'>
140
182
  Code coverage generated by
141
183
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
142
- at 2026-04-14T09:10:10.519Z
184
+ at 2026-04-14T12:55:53.555Z
143
185
  </div>
144
186
  <script src="prettify.js"></script>
145
187
  <script>
@@ -193,7 +193,7 @@
193
193
  <div class='footer quiet pad2 space-top1 center small'>
194
194
  Code coverage generated by
195
195
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
196
- at 2026-04-14T09:10:10.519Z
196
+ at 2026-04-14T12:55:53.555Z
197
197
  </div>
198
198
  <script src="prettify.js"></script>
199
199
  <script>
@@ -289,7 +289,7 @@
289
289
  <div class='footer quiet pad2 space-top1 center small'>
290
290
  Code coverage generated by
291
291
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
292
- at 2026-04-14T09:10:10.519Z
292
+ at 2026-04-14T12:55:53.555Z
293
293
  </div>
294
294
  <script src="prettify.js"></script>
295
295
  <script>
@@ -328,7 +328,7 @@ export default {
328
328
  <div class='footer quiet pad2 space-top1 center small'>
329
329
  Code coverage generated by
330
330
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
331
- at 2026-04-14T09:10:10.519Z
331
+ at 2026-04-14T12:55:53.555Z
332
332
  </div>
333
333
  <script src="prettify.js"></script>
334
334
  <script>
@@ -265,7 +265,7 @@ export default {
265
265
  <div class='footer quiet pad2 space-top1 center small'>
266
266
  Code coverage generated by
267
267
  <a href="https://istanbul.js.org/" target="_blank" rel="noopener noreferrer">istanbul</a>
268
- at 2026-04-14T09:10:10.519Z
268
+ at 2026-04-14T12:55:53.555Z
269
269
  </div>
270
270
  <script src="prettify.js"></script>
271
271
  <script>
package/dist/index.d.ts CHANGED
@@ -1,149 +1,166 @@
1
1
  declare namespace _default {
2
- let rules: {
3
- 'import-specifiers-per-line': {
4
- meta: {
5
- type: string;
6
- docs: {
7
- description: string;
8
- };
9
- fixable: string;
10
- schema: {
11
- type: string;
12
- properties: {
13
- maxSpecifiers: {
14
- type: string;
15
- default: number;
2
+ export namespace plugins {
3
+ namespace tcy {
4
+ let rules: {
5
+ 'import-specifiers-per-line': {
6
+ meta: {
7
+ type: string;
8
+ docs: {
9
+ description: string;
16
10
  };
17
- maxLen: {
11
+ fixable: string;
12
+ schema: {
18
13
  type: string;
19
- default: number;
20
- };
14
+ properties: {
15
+ maxSpecifiers: {
16
+ type: string;
17
+ default: number;
18
+ };
19
+ maxLen: {
20
+ type: string;
21
+ default: number;
22
+ };
23
+ };
24
+ additionalProperties: boolean;
25
+ }[];
26
+ };
27
+ create(context: any): {
28
+ ImportDeclaration(node: any): void;
21
29
  };
22
- additionalProperties: boolean;
23
- }[];
24
- };
25
- create(context: any): {
26
- ImportDeclaration(node: any): void;
27
- };
28
- };
29
- 'array-elements-per-line': {
30
- meta: {
31
- type: string;
32
- docs: {
33
- description: string;
34
- category: string;
35
- recommended: boolean;
36
- };
37
- fixable: string;
38
- schema: never[];
39
- };
40
- create(context: any): {
41
- ArrayExpression(node: any): void;
42
- };
43
- };
44
- 'export-specifiers-per-line': {
45
- meta: {
46
- type: string;
47
- docs: {
48
- description: string;
49
30
  };
50
- fixable: string;
51
- schema: never[];
52
- };
53
- create(context: any): {
54
- ExportNamedDeclaration(node: any): void;
55
- };
56
- };
57
- 'jsx-expression-string-literals': {
58
- meta: {
59
- type: string;
60
- docs: {
61
- description: string;
31
+ 'array-elements-per-line': {
32
+ meta: {
33
+ type: string;
34
+ docs: {
35
+ description: string;
36
+ category: string;
37
+ recommended: boolean;
38
+ };
39
+ fixable: string;
40
+ schema: never[];
41
+ };
42
+ create(context: any): {
43
+ ArrayExpression(node: any): void;
44
+ };
62
45
  };
63
- fixable: string;
64
- schema: never[];
65
- };
66
- create(context: any): {
67
- JSXAttribute(node: any): void;
68
- };
69
- };
70
- 'enforce-tailwind-important': {
71
- meta: {
72
- type: string;
73
- docs: {
74
- description: string;
75
- recommended: boolean;
46
+ 'export-specifiers-per-line': {
47
+ meta: {
48
+ type: string;
49
+ docs: {
50
+ description: string;
51
+ };
52
+ fixable: string;
53
+ schema: never[];
54
+ };
55
+ create(context: any): {
56
+ ExportNamedDeclaration(node: any): void;
57
+ };
76
58
  };
77
- fixable: string;
78
- schema: never[];
79
- messages: {
80
- missingImportant: string;
59
+ 'jsx-expression-string-literals': {
60
+ meta: {
61
+ type: string;
62
+ docs: {
63
+ description: string;
64
+ };
65
+ fixable: string;
66
+ schema: never[];
67
+ };
68
+ create(context: any): {
69
+ JSXAttribute(node: any): void;
70
+ };
81
71
  };
82
- };
83
- create(context: any): {
84
- JSXAttribute(node: any): void;
85
- VariableDeclarator(node: any): void;
86
- };
87
- };
88
- 'v-model-name-match': {
89
- meta: {
90
- type: string;
91
- docs: {
92
- description: string;
93
- recommended: boolean;
72
+ 'enforce-tailwind-important': {
73
+ meta: {
74
+ type: string;
75
+ docs: {
76
+ description: string;
77
+ recommended: boolean;
78
+ };
79
+ fixable: string;
80
+ schema: never[];
81
+ messages: {
82
+ missingImportant: string;
83
+ };
84
+ };
85
+ create(context: any): {
86
+ JSXAttribute(node: any): void;
87
+ VariableDeclarator(node: any): void;
88
+ };
94
89
  };
95
- schema: never[];
96
- messages: {
97
- mismatch: string;
90
+ 'v-model-name-match': {
91
+ meta: {
92
+ type: string;
93
+ docs: {
94
+ description: string;
95
+ recommended: boolean;
96
+ };
97
+ schema: never[];
98
+ messages: {
99
+ mismatch: string;
100
+ };
101
+ };
102
+ create(context: any): {
103
+ JSXOpeningElement(node: any): void;
104
+ };
98
105
  };
99
- };
100
- create(context: any): {
101
- JSXOpeningElement(node: any): void;
102
- };
103
- };
104
- 'decorator-type-enforcement': {
105
- meta: {
106
- type: string;
107
- docs: {
108
- description: string;
109
- category: string;
110
- recommended: boolean;
106
+ 'decorator-type-enforcement': {
107
+ meta: {
108
+ type: string;
109
+ docs: {
110
+ description: string;
111
+ category: string;
112
+ recommended: boolean;
113
+ };
114
+ fixable: string;
115
+ schema: never[];
116
+ };
117
+ create(context: any): {
118
+ PropertyDefinition(node: any): void;
119
+ };
111
120
  };
112
- fixable: string;
113
- schema: never[];
114
- };
115
- create(context: any): {
116
- PropertyDefinition(node: any): void;
117
- };
118
- };
119
- 'vuejs-define-component': {
120
- meta: {
121
- type: string;
122
- docs: {
123
- description: string;
124
- recommended: boolean;
121
+ 'vuejs-define-component': {
122
+ meta: {
123
+ type: string;
124
+ docs: {
125
+ description: string;
126
+ recommended: boolean;
127
+ };
128
+ schema: never[];
129
+ };
130
+ create(context: any): {
131
+ ExportDefaultDeclaration(node: any): void;
132
+ };
125
133
  };
126
- schema: never[];
127
- };
128
- create(context: any): {
129
- ExportDefaultDeclaration(node: any): void;
130
- };
131
- };
132
- 'vuejs-define-workspace': {
133
- meta: {
134
- type: string;
135
- docs: {
136
- description: string;
137
- recommended: boolean;
134
+ 'vuejs-define-workspace': {
135
+ meta: {
136
+ type: string;
137
+ docs: {
138
+ description: string;
139
+ recommended: boolean;
140
+ };
141
+ schema: never[];
142
+ };
143
+ create(context: any): {
144
+ ExportDefaultDeclaration?: undefined;
145
+ } | {
146
+ ExportDefaultDeclaration(node: any): void;
147
+ };
138
148
  };
139
- schema: never[];
140
- };
141
- create(context: any): {
142
- ExportDefaultDeclaration?: undefined;
143
- } | {
144
- ExportDefaultDeclaration(node: any): void;
145
149
  };
146
- };
150
+ }
151
+ }
152
+ let rules_1: {
153
+ 'tcy/import-specifiers-per-line': (string | {
154
+ maxSpecifiers: number;
155
+ })[];
156
+ 'tcy/export-specifiers-per-line': string;
157
+ 'tcy/array-elements-per-line': string;
158
+ 'tcy/jsx-expression-string-literals': string;
159
+ 'tcy/enforce-tailwind-important': string;
160
+ 'tcy/v-model-name-match': string;
161
+ 'tcy/vuejs-define-component': string;
162
+ 'tcy/vuejs-define-workspace': string;
147
163
  };
164
+ export { rules_1 as rules };
148
165
  }
149
166
  export default _default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tcy/eslint-rules",
3
- "version": "1.3.3",
3
+ "version": "1.4.2",
4
4
  "description": "```typescript import { plugin as customRules } from 'tcy@eslint-rules/src/index.mjs';",
5
5
  "homepage": "https://github.com/tcastelly/eslint-rules#readme",
6
6
  "bugs": {
package/src/index.js CHANGED
@@ -9,15 +9,29 @@ import vuejsDefineComponent from './vuejs-define-component.js'
9
9
  import vuejsDefineWorkspace from './vuejs-define-workspace.js'
10
10
 
11
11
  export default {
12
+ plugins: {
13
+ tcy: {
14
+ rules: {
15
+ 'import-specifiers-per-line': importSpecifiersPerLineRule,
16
+ 'array-elements-per-line': arrayElementsPerLineRule,
17
+ 'export-specifiers-per-line': exportSpecifiersPerLineRule,
18
+ 'jsx-expression-string-literals': jsxExpressionStringLiterals,
19
+ 'enforce-tailwind-important': enforceTailwindImportant,
20
+ 'v-model-name-match': vModelNameMatch,
21
+ 'decorator-type-enforcement': decoratorTypeEnforcement,
22
+ 'vuejs-define-component': vuejsDefineComponent,
23
+ 'vuejs-define-workspace': vuejsDefineWorkspace,
24
+ }
25
+ }
26
+ },
12
27
  rules: {
13
- 'import-specifiers-per-line': importSpecifiersPerLineRule,
14
- 'array-elements-per-line': arrayElementsPerLineRule,
15
- 'export-specifiers-per-line': exportSpecifiersPerLineRule,
16
- 'jsx-expression-string-literals': jsxExpressionStringLiterals,
17
- 'enforce-tailwind-important': enforceTailwindImportant,
18
- 'v-model-name-match': vModelNameMatch,
19
- 'decorator-type-enforcement': decoratorTypeEnforcement,
20
- 'vuejs-define-component': vuejsDefineComponent,
21
- 'vuejs-define-workspace': vuejsDefineWorkspace,
28
+ 'tcy/import-specifiers-per-line': ['error', { maxSpecifiers: 4 }],
29
+ 'tcy/export-specifiers-per-line': 'error',
30
+ 'tcy/array-elements-per-line': 'error',
31
+ 'tcy/jsx-expression-string-literals': 'error',
32
+ 'tcy/enforce-tailwind-important': 'error',
33
+ 'tcy/v-model-name-match': 'error',
34
+ 'tcy/vuejs-define-component': 'error',
35
+ 'tcy/vuejs-define-workspace': 'error',
22
36
  },
23
37
  };