@scayle/eslint-config-storefront 4.8.0 → 4.8.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,25 @@
1
1
  # @aboutyou/eslint-config-sfc
2
2
 
3
+ ## 4.8.2
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependency `typescript-eslint@8.60.0` to `typescript-eslint@8.65.0`
8
+
9
+ ## 4.8.1
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependency `@antfu/eslint-config@^8.0.0` to `@antfu/eslint-config@^9.0.0`
14
+ - Updated dependency `@eslint/eslintrc@^3.2.0` to `@eslint/eslintrc@^3.3.5`
15
+ - Updated dependency `eslint-config-flat-gitignore@^2.0.0` to `eslint-config-flat-gitignore@^2.2.0`
16
+ - Updated dependency `eslint-flat-config-utils@^3.0.0` to `eslint-flat-config-utils@^3.2.0`
17
+ - Updated dependency `eslint-plugin-import-x@^4.16.1` to `eslint-plugin-import-x@^4.16.2`
18
+ - Updated dependency `eslint-plugin-promise@^7.2.1` to `eslint-plugin-promise@^7.3.0`
19
+ - Updated dependency `eslint-plugin-sonarjs@^4.0.0` to `eslint-plugin-sonarjs@^4.0.3`
20
+ - Updated dependency `local-pkg@^1.0.0` to `local-pkg@^1.2.1`
21
+ - Updated dependency `typescript-eslint@8.57.2` to `typescript-eslint@8.60.0`
22
+
3
23
  ## 4.8.0
4
24
 
5
25
  ### Minor Changes
@@ -192,7 +212,6 @@
192
212
  - Added eslint plugin `eslint-plugin-import-x` to support additional import-related rules.
193
213
 
194
214
  The following rules have been added and set to throw errors:
195
-
196
215
  - `'import-x/consistent-type-specifier-style': ['error', 'prefer-top-level']'`
197
216
  - `'import-x/first': 'error'`
198
217
  - `'import-x/no-duplicates': 'error'`
@@ -309,7 +328,6 @@
309
328
  ### Minor Changes
310
329
 
311
330
  - We've updated to `eslint-plugin-sonarjs@3.x`. This fixes the executions of multiple SonarJS rules like "cognitive-complexity" during linting and also adds additional new rules.
312
-
313
331
  - Check the official [`eslint-plugin-sonarjs` - CHANGELOG.md](https://github.com/SonarSource/SonarJS/blob/master/packages/jsts/src/rules/CHANGELOG.md) for more details.
314
332
 
315
333
  ### Patch Changes
@@ -456,7 +474,6 @@
456
474
  ### Major Changes
457
475
 
458
476
  - **Changed NPM package names**
459
-
460
477
  - **Breaking**: Change package scope and name of `@aboutyou/scayle-sfc-nuxt` to `@scayle/storefront-nuxt2`
461
478
  - **Breaking**: Change package scope and name of `@aboutyou/sfc-nuxt3` to `@scayle/storefront-nuxt`
462
479
  - **Breaking**: Change package scope and name of `@aboutyou/scayle-sfc-lib` to `@scayle/storefront-core`
@@ -465,7 +482,6 @@
465
482
 
466
483
  _NOTE: Due to the changes of the NPM package scope from `@aboutyou` to `@scayle`,
467
484
  it is required to change the consuming projects local `.npmrc` file as follows:_
468
-
469
485
  - Before:
470
486
 
471
487
  ```
@@ -486,7 +502,6 @@
486
502
  ### Major Changes
487
503
 
488
504
  - **Changed NPM package names**
489
-
490
505
  - **Breaking**: Change package scope and name of `@aboutyou/scayle-sfc-nuxt` to `@scayle/storefront-nuxt2`
491
506
  - **Breaking**: Change package scope and name of `@aboutyou/sfc-nuxt3` to `@scayle/storefront-nuxt`
492
507
  - **Breaking**: Change package scope and name of `@aboutyou/scayle-sfc-lib` to `@scayle/storefront-core``
@@ -495,7 +510,6 @@
495
510
 
496
511
  Due to the changes of the NPM package scope from `@aboutyou` to `@scayle`,
497
512
  it is required to change the consuming projects local `.npmrc` file as follows:
498
-
499
513
  - Before: `@aboutyou:registry=https://gitlab.com/api/v4/packages/npm/`
500
514
  - After: `@scayle:registry=https://gitlab.com/api/v4/packages/npm/`
501
515
 
package/README.md CHANGED
@@ -56,7 +56,7 @@ Add the following settings to your `.vscode/settings.json`:
56
56
  // Auto fix
57
57
  "editor.codeActionsOnSave": {
58
58
  "source.fixAll.eslint": "explicit",
59
- "source.organizeImports": "never"
59
+ "source.organizeImports": "never",
60
60
  },
61
61
 
62
62
  // Enable eslint for all supported languages
@@ -70,8 +70,8 @@ Add the following settings to your `.vscode/settings.json`:
70
70
  "markdown",
71
71
  "json",
72
72
  "jsonc",
73
- "yaml"
74
- ]
73
+ "yaml",
74
+ ],
75
75
  }
76
76
  ```
77
77
 
@@ -28,10 +28,12 @@ import { importX } from './importX.mjs'
28
28
  * @param {string=} config.typescript.tsconfigPath
29
29
  * @returns {FlatConfigComposer<Linter.FlatConfig<Linter.RulesRecord>, never>} Returns a FlatConfigComposer object to be consumed in projects eslint.config.mjs files
30
30
  */
31
- export const eslintConfigStorefront = function(config = {
32
- isNuxt: isPackageExists('@nuxt/eslint'),
33
- typescript: { tsconfigPath: undefined },
34
- }) {
31
+ export const eslintConfigStorefront = function (
32
+ config = {
33
+ isNuxt: isPackageExists('@nuxt/eslint'),
34
+ typescript: { tsconfigPath: undefined },
35
+ },
36
+ ) {
35
37
  const flatConfigComposer = new FlatConfigComposer()
36
38
  const isNuxtProject = config.isNuxt
37
39
 
@@ -62,21 +64,24 @@ export const eslintConfigStorefront = function(config = {
62
64
  const CURLY_RULE = ['error', 'all']
63
65
 
64
66
  const TYPESCRIPT_RULES = {
65
- 'curly': CURLY_RULE,
67
+ curly: CURLY_RULE,
66
68
  '@typescript-eslint/no-explicit-any': ['warn', { ignoreRestArgs: true }],
67
- '@typescript-eslint/no-empty-object-type': ['error', {
68
- 'allowInterfaces': 'always',
69
- }],
69
+ '@typescript-eslint/no-empty-object-type': [
70
+ 'error',
71
+ {
72
+ allowInterfaces: 'always',
73
+ },
74
+ ],
70
75
  '@typescript-eslint/no-unused-vars': [
71
76
  'error',
72
77
  {
73
- 'args': 'all',
74
- 'argsIgnorePattern': '^_',
75
- 'caughtErrors': 'all',
76
- 'caughtErrorsIgnorePattern': '^_',
77
- 'destructuredArrayIgnorePattern': '^_',
78
- 'varsIgnorePattern': '^_',
79
- 'ignoreRestSiblings': true,
78
+ args: 'all',
79
+ argsIgnorePattern: '^_',
80
+ caughtErrors: 'all',
81
+ caughtErrorsIgnorePattern: '^_',
82
+ destructuredArrayIgnorePattern: '^_',
83
+ varsIgnorePattern: '^_',
84
+ ignoreRestSiblings: true,
80
85
  },
81
86
  ],
82
87
  }
@@ -91,11 +96,15 @@ export const eslintConfigStorefront = function(config = {
91
96
  ]
92
97
 
93
98
  const GLOBAL_RULES = {
94
- 'curly': CURLY_RULE,
99
+ curly: CURLY_RULE,
95
100
  'node/prefer-global/process': 'off',
96
101
  }
97
102
 
98
- const TEST_RULES = { 'no-console': 'off' }
103
+ const TEST_RULES = {
104
+ 'no-console': 'off',
105
+ '@typescript-eslint/no-explicit-any': 'off',
106
+ 'promise/avoid-new': 'off',
107
+ }
99
108
 
100
109
  const IGNORE_PATTERNS = ['**/fixtures/**/*', '**/*.jsonc']
101
110
 
@@ -103,15 +112,15 @@ export const eslintConfigStorefront = function(config = {
103
112
  // don't need to be extended from `@antfu/eslint-config` if it is used
104
113
  const nonNuxtRules = !isNuxtProject
105
114
  ? combine(
106
- gitignore(),
107
- ignores(),
108
- importX(),
109
- javascript(),
110
- typescript(config.typescript),
111
- jsdoc(),
112
- tseslint.configs.recommended,
113
- [{ rules: TYPESCRIPT_RULES }],
114
- )
115
+ gitignore(),
116
+ ignores(),
117
+ importX(),
118
+ javascript(),
119
+ typescript(config.typescript),
120
+ jsdoc(),
121
+ tseslint.configs.recommended,
122
+ [{ rules: TYPESCRIPT_RULES }],
123
+ )
115
124
  : {}
116
125
 
117
126
  const configs = [
@@ -142,7 +151,5 @@ export const eslintConfigStorefront = function(config = {
142
151
  },
143
152
  ]
144
153
 
145
- return flatConfigComposer.append(
146
- ...configs,
147
- )
154
+ return flatConfigComposer.append(...configs)
148
155
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@scayle/eslint-config-storefront",
3
- "version": "4.8.0",
3
+ "version": "4.8.2",
4
4
  "description": "SCAYLE Commerce Engine specific eslint configuration",
5
5
  "author": "SCAYLE Commerce Engine",
6
6
  "license": "MIT",
@@ -37,26 +37,23 @@
37
37
  "typescript": ">=5.4.0"
38
38
  },
39
39
  "dependencies": {
40
- "@antfu/eslint-config": "^8.0.0",
41
- "@eslint/eslintrc": "^3.2.0",
42
- "eslint-config-flat-gitignore": "^2.0.0",
43
- "eslint-flat-config-utils": "^3.0.0",
44
- "eslint-plugin-import-x": "^4.16.1",
45
- "eslint-plugin-promise": "^7.2.1",
46
- "eslint-plugin-sonarjs": "^4.0.0",
47
- "local-pkg": "^1.0.0",
48
- "typescript-eslint": "8.57.2"
40
+ "@antfu/eslint-config": "^9.0.0",
41
+ "@eslint/eslintrc": "^3.3.5",
42
+ "eslint-config-flat-gitignore": "^2.2.0",
43
+ "eslint-flat-config-utils": "^3.2.0",
44
+ "eslint-plugin-import-x": "^4.16.2",
45
+ "eslint-plugin-promise": "^7.3.0",
46
+ "eslint-plugin-sonarjs": "^4.0.3",
47
+ "local-pkg": "^1.2.1",
48
+ "typescript-eslint": "8.65.0"
49
49
  },
50
50
  "devDependencies": {
51
- "dprint": "0.53.2",
52
- "eslint": "10.2.0",
53
- "eslint-formatter-gitlab": "7.0.1",
54
- "publint": "0.3.18",
55
- "typescript": "5.9.3"
51
+ "eslint": "10.8.0",
52
+ "eslint-formatter-gitlab": "7.2.0",
53
+ "publint": "0.3.22",
54
+ "typescript": "6.0.3"
56
55
  },
57
56
  "scripts": {
58
- "format": "dprint check",
59
- "format:fix": "dprint fmt",
60
57
  "lint": "eslint .",
61
58
  "lint:ci": "eslint . --format gitlab",
62
59
  "lint:fix": "eslint . --fix",