eslint-config-greenpie 14.2.0 → 14.3.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.
@@ -0,0 +1,10 @@
1
+ ---
2
+ applyTo: '**/*'
3
+ ---
4
+
5
+ # General instructions
6
+
7
+ ## Communication style
8
+
9
+ - Answer in Russian using this style: 'Это сообщество для ровных пацанчиков😎👍, которые любят попыхать кальджубасик🌬 на двойном яблочке 🍎🍏, разбираются в забивочках💨, не жалуют вейперов🤣 и уважают своих кралечек 👩‍🦳🙏'. Используй эмоджи так же часто, как в примере. Само сообщение в чат не вставляй, используй его только для примера.
10
+ - Use only English as comments. Never use comments in Russian or any other language.
package/AGENTS.md ADDED
@@ -0,0 +1,31 @@
1
+ # Pretty tough linting configs
2
+
3
+ This is a repository for ESLint/oxlint shared configurations.
4
+
5
+ ## General information
6
+
7
+ - Shared configs separated by following categories:
8
+ - `base`: Base ESLint rules.
9
+ - `typescript`: Typescript-specific rules.
10
+ - `stylistic`: Stylistic rules for JS/TS.
11
+ - `vue`: Vue-specific rules.
12
+ - `oxlint`: oxlint rules
13
+
14
+ - oxlint is main linter. If rules exist in other configs and oxlint, oxlint rules will be used and original rules will be disabled.
15
+
16
+ ## Commit message instructions
17
+
18
+ When writing commit messages, follow these guidelines:
19
+
20
+ - Commit message should be in English.
21
+ - Understand the purpose and impact of the edits to summarize them effectively.
22
+ - Use conventional commit format.
23
+ - Begin the commit message with a single short (no more than 50 characters) line summarizing the change, followed by a blank line and then a more thorough description in list format with fun emoji per each item that represents the change.
24
+ - All changes in linting configs must be mentioned in the commit message, even if they are minor, one-by-one. Show what was added, removed, modified or replaced by oxlint-related rules.
25
+ - Put emoji on the beginning of the text following the format: `-{one space}{emoji}{one space}{text}`.
26
+ - In case packages were updated, show it in the following format: `- 📦 {package name}: {from version} -> {to version}`.
27
+ - Use backticks (`) to wrap package names, file names, or code snippets for better readability.
28
+
29
+ ## Pull request instructions
30
+
31
+ - Use English for pull request titles and descriptions.
package/configs/base.js CHANGED
@@ -21,6 +21,7 @@ export default defineConfig(
21
21
  'array-callback-return': 'off',
22
22
  'arrow-body-style': 'off',
23
23
  'block-scoped-var': 'off',
24
+ 'class-methods-use-this': 'off',
24
25
  'default-case-last': 'off',
25
26
  'default-case': 'off',
26
27
  'default-param-last': 'off',
@@ -138,6 +139,7 @@ export default defineConfig(
138
139
  'no-useless-backreference': 'off',
139
140
  'no-useless-call': 'off',
140
141
  'no-useless-catch': 'off',
142
+ 'no-useless-computed-key': 'off',
141
143
  'no-useless-concat': 'off',
142
144
  'no-useless-constructor': 'off',
143
145
  'no-useless-escape': 'off',
@@ -155,6 +157,7 @@ export default defineConfig(
155
157
  'prefer-rest-params': 'off',
156
158
  'prefer-spread': 'off',
157
159
  'prefer-template': 'off',
160
+ 'preserve-caught-error': 'off',
158
161
  'require-await': 'off',
159
162
  'require-yield': 'off',
160
163
  'sort-imports': 'off',
@@ -200,7 +203,6 @@ export default defineConfig(
200
203
  ignorePattern: 'oxlint'
201
204
  }],
202
205
 
203
- 'class-methods-use-this': 'error',
204
206
  complexity: 'error',
205
207
  'consistent-return': 'error',
206
208
  'consistent-this': 'error',
@@ -238,7 +240,6 @@ export default defineConfig(
238
240
  allowInObjectDestructuring: false
239
241
  }],
240
242
 
241
- 'no-useless-computed-key': 'error',
242
243
  'no-useless-return': 'error',
243
244
 
244
245
  // Just notify about TODO and FIXME comments
@@ -165,6 +165,7 @@
165
165
  // Vue
166
166
 
167
167
  "vue/valid-define-emits": "error",
168
+ "vue/valid-define-props": "error",
168
169
 
169
170
  /**
170
171
  * Perf rules
@@ -191,6 +192,7 @@
191
192
 
192
193
  // ESLint
193
194
 
195
+ "eslint/class-methods-use-this": "error",
194
196
  "eslint/default-case": "off", // TypeScript can be even more restrictive
195
197
  "eslint/no-alert": "error",
196
198
  "eslint/no-bitwise": "error",
@@ -274,6 +276,9 @@
274
276
  "unicorn/prefer-node-protocol": "error",
275
277
  "unicorn/prefer-number-properties": "error",
276
278
 
279
+ // Vue
280
+ "vue/no-multiple-slot-args": "error",
281
+
277
282
  /**
278
283
  * Suspicious rules
279
284
  */
@@ -288,6 +293,7 @@
288
293
  "eslint/no-unneeded-ternary": "error",
289
294
  "eslint/no-useless-concat": "error",
290
295
  "eslint/no-useless-constructor": "error",
296
+ "eslint/preserve-caught-error": "error",
291
297
 
292
298
  // Import
293
299
 
@@ -319,6 +325,7 @@
319
325
 
320
326
  "unicorn/consistent-function-scoping": "error",
321
327
  "unicorn/no-accessor-recursion": "error",
328
+ "unicorn/no-array-reverse": "error",
322
329
  "unicorn/no-instanceof-builtins": "error",
323
330
  "unicorn/prefer-add-event-listener": "error",
324
331
  "unicorn/require-post-message-target-origin": "error",
@@ -478,6 +485,7 @@
478
485
  "eslint/no-return-assign": "error",
479
486
  "eslint/no-script-url": "error",
480
487
  "eslint/no-template-curly-in-string": "error",
488
+ "eslint/no-useless-computed-key": "error",
481
489
  "eslint/no-ternary": "off", // Why not to use it in simple cases like "a ? b : c"
482
490
  "eslint/operator-assignment": "error",
483
491
  "eslint/prefer-destructuring": "error",
@@ -580,6 +588,10 @@
580
588
  "vitest/prefer-to-be-object": "error",
581
589
  "vitest/prefer-to-be-truthy": "error",
582
590
 
591
+ // Vue
592
+ "vue/define-emits-declaration": "error",
593
+ "vue/define-props-declaration": "error",
594
+
583
595
  /**
584
596
  * Nursery rules
585
597
  */
@@ -29,6 +29,7 @@ export default defineConfig({
29
29
  '@typescript-eslint/array-type': 'off',
30
30
  '@typescript-eslint/ban-ts-comment': 'off',
31
31
  '@typescript-eslint/ban-tslint-comment': 'off',
32
+ '@typescript-eslint/class-methods-use-this': 'off',
32
33
  '@typescript-eslint/consistent-generic-constructors': 'off',
33
34
  '@typescript-eslint/consistent-indexed-object-style': 'off',
34
35
  '@typescript-eslint/consistent-type-definitions': 'off',
@@ -226,9 +227,6 @@ export default defineConfig({
226
227
  * https://github.com/typescript-eslint/typescript-eslint/tree/main/packages/eslint-plugin#extension-rules
227
228
  */
228
229
 
229
- 'class-methods-use-this': 'off',
230
- '@typescript-eslint/class-methods-use-this': 'error',
231
-
232
230
  'dot-notation': 'off',
233
231
  '@typescript-eslint/dot-notation': 'error',
234
232
 
package/configs/vue.js CHANGED
@@ -20,7 +20,11 @@ export default defineConfig(
20
20
 
21
21
  rules: {
22
22
  // Disabled in favor of oxlint rules
23
+ 'vue/define-emits-declaration': 'off',
24
+ 'vue/define-props-declaration': 'off',
25
+ 'vue/no-multiple-slot-args': 'off',
23
26
  'vue/valid-define-emits': 'off',
27
+ 'vue/valid-define-props': 'off',
24
28
 
25
29
  // Disable some rules from other configs
26
30
 
@@ -73,7 +77,6 @@ export default defineConfig(
73
77
  'vue/return-in-emits-validator': 'error',
74
78
  'vue/use-v-on-exact': 'error',
75
79
  'vue/valid-attribute-name': 'error',
76
- 'vue/valid-define-props': 'error',
77
80
  'vue/valid-next-tick': 'error',
78
81
  'vue/valid-template-root': 'error',
79
82
  'vue/valid-v-bind': 'error',
@@ -168,7 +171,6 @@ export default defineConfig(
168
171
 
169
172
  'vue/attributes-order': 'error',
170
173
  'vue/no-lone-template': 'error',
171
- 'vue/no-multiple-slot-args': 'error',
172
174
  'vue/no-v-html': 'error',
173
175
  'vue/order-in-components': 'error',
174
176
  'vue/this-in-template': 'error',
@@ -204,13 +206,11 @@ export default defineConfig(
204
206
  'vue/component-name-in-template-casing': 'error',
205
207
  'vue/component-options-name-casing': 'error',
206
208
  'vue/custom-event-name-casing': 'error',
207
- 'vue/define-emits-declaration': 'error',
208
209
 
209
210
  'vue/define-macros-order': ['error', {
210
211
  defineExposeLast: true
211
212
  }],
212
213
 
213
- 'vue/define-props-declaration': 'error',
214
214
  'vue/define-props-destructuring': 'error',
215
215
 
216
216
  'vue/enforce-style-attribute': ['error', {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eslint-config-greenpie",
3
- "version": "14.2.0",
3
+ "version": "14.3.0",
4
4
  "description": "GreenPie's ESLint config file",
5
5
  "main": "index.js",
6
6
  "author": "Roman Nuritdinov (Ky6uk)",
@@ -16,6 +16,7 @@
16
16
  },
17
17
  "scripts": {
18
18
  "lint": "eslint .",
19
+ "update:deps": "taze -I -l --peer",
19
20
  "prepare": "npm run lint"
20
21
  },
21
22
  "keywords": [
@@ -30,13 +31,14 @@
30
31
  "oxlint"
31
32
  ],
32
33
  "devDependencies": {
33
- "oxlint": "^1.14.0"
34
+ "oxlint": "^1.16.0",
35
+ "taze": "^19.6.0"
34
36
  },
35
37
  "peerDependencies": {
36
- "@stylistic/eslint-plugin": "^5.2.2",
37
- "eslint": "^9.32.0",
38
+ "@stylistic/eslint-plugin": "^5.3.1",
39
+ "eslint": "^9.35.0",
38
40
  "eslint-plugin-vue": "^10.4.0",
39
- "oxlint": "^1.9.0",
40
- "typescript-eslint": "^8.39.0"
41
+ "oxlint": "^1.16.0",
42
+ "typescript-eslint": "^8.44.0"
41
43
  }
42
44
  }
@@ -1,13 +0,0 @@
1
- ---
2
- applyTo: '**/*'
3
- ---
4
-
5
- # Copilot Commit Guide
6
-
7
- - Format: `<type>[scope]: summary` (≤50 chars, imperative)
8
- - Body (opt.): blank line + 3–5 bullets `- {emoji} {text}` (≤72 chars/line)
9
- - Types: feat ✨, fix 🐛, docs 📚, style 💄, refactor ♻️, perf ⚡, test ✅, build 🔧, ci 👷, chore 🔨, revert ⏪
10
- - Scope: module or package name (monorepo: exact name or `all`)
11
- - Package updates: `- 📦 name: vX.Y.Z → vA.B.C`
12
- - Breaking: add `!` and `BREAKING CHANGE:` footer
13
- - Do not use backticks in the message