@cenk1cenk2/eslint-config 3.1.3 → 3.1.4

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,3 +1,10 @@
1
+ ## [3.1.4](https://gitlab.kilic.dev/config/eslint-config/compare/v3.1.3...v3.1.4) (2024-10-19)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * update configuration for linting vue ([ae76bbd](https://gitlab.kilic.dev/config/eslint-config/commit/ae76bbda62bea70a18fea28d3c1446e67da08872))
7
+
1
8
  ## [3.1.3](https://gitlab.kilic.dev/config/eslint-config/compare/v3.1.2...v3.1.3) (2024-10-19)
2
9
 
3
10
 
package/javascript.js CHANGED
@@ -1,12 +1,16 @@
1
1
  import JavascriptPlugin from '@eslint/js'
2
2
  import StylisticPlugin from '@stylistic/eslint-plugin'
3
+ import TypescriptEslint from 'typescript-eslint'
4
+ import { EXTENSIONS_JAVASCRIPT, EXTENSIONS } from './constants.js'
3
5
 
4
6
  import ConfigImports from './import.js'
5
- import { EXTENSIONS } from './constants.js'
6
7
 
7
8
  /** @type {import("eslint").Linter.Config[]} */
8
9
  export default [
9
- JavascriptPlugin.configs.recommended,
10
+ {
11
+ name: 'recommended',
12
+ ...JavascriptPlugin.configs.recommended
13
+ },
10
14
 
11
15
  ...ConfigImports,
12
16
 
@@ -33,8 +37,8 @@ export default [
33
37
  'stylistic/linebreak-style': ['error', 'unix'],
34
38
  'sort-imports': 'off',
35
39
  'stylistic/indent': ['error', 2],
36
- 'stylistic/brace-style': ['error', '1tbs', { allowSingleLine: true }],
37
- 'stylistic/comma-spacing': ['error', { before: false, after: true }],
40
+ 'stylistic/brace-style': ['error', '1tbs', { allowSingleLine: true } ],
41
+ 'stylistic/comma-spacing': ['error', { before: false, after: true } ],
38
42
  'stylistic/func-call-spacing': ['error', 'never'],
39
43
  'stylistic/max-len': [
40
44
  'error',
@@ -153,5 +157,10 @@ export default [
153
157
  }
154
158
  ]
155
159
  }
160
+ },
161
+
162
+ {
163
+ ...TypescriptEslint.configs.disableTypeChecked,
164
+ files: [...EXTENSIONS_JAVASCRIPT]
156
165
  }
157
166
  ]
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cenk1cenk2/eslint-config",
3
- "version": "3.1.3",
3
+ "version": "3.1.4",
4
4
  "description": "Eslint configuration for my taste.",
5
5
  "main": "index.js",
6
6
  "repository": "git@gitlab.kilic.dev:config/eslint-config.git",
@@ -1,15 +1,19 @@
1
- import SveltePlugin from 'eslint-plugin-svelte'
2
1
  import TypescriptParser from '@typescript-eslint/parser'
2
+ import SveltePlugin from 'eslint-plugin-svelte'
3
3
  import SvelteParser from 'svelte-eslint-parser'
4
4
 
5
+ import { EXTENSIONS_SVELTE } from './constants.js'
5
6
  import ConfigTypescript from './typescript-dynamic.js'
6
- import { EXTENSIONS_SVELTE, EXTENSIONS_TYPESCRIPT } from './constants.js'
7
7
 
8
8
  /** @type {import("eslint").Linter.Config[]} */
9
9
  export default [
10
10
  ...SveltePlugin.configs['flat/recommended'],
11
11
 
12
- ...ConfigTypescript,
12
+ ...ConfigTypescript.map((config) => {
13
+ config.files = [...(config.files ?? []), ...EXTENSIONS_SVELTE]
14
+
15
+ return config
16
+ }),
13
17
 
14
18
  {
15
19
  name: 'cenk1cenk2/svelte/typescript/recommended',
@@ -4,8 +4,9 @@ import ConfigTypescript from './typescript.js'
4
4
  /** @type {import("eslint").Linter.Config[]} */
5
5
  export default [
6
6
  ...ConfigTypescript,
7
+
7
8
  {
8
- name: 'cenk1cenk2/typescript-dynamic/recommended',
9
+ name: 'cenk1cenk2/typescript/dynamic',
9
10
  files: [...EXTENSIONS_TYPESCRIPT],
10
11
  languageOptions: {
11
12
  parserOptions: {
@@ -26,7 +27,7 @@ export default [
26
27
  disallowTypeAnnotations: true
27
28
  }
28
29
  ],
29
- '@typescript-eslint/consistent-type-exports': ['error', { fixMixedExportsWithInlineTypeSpecifier: false }]
30
+ '@typescript-eslint/consistent-type-exports': ['error', { fixMixedExportsWithInlineTypeSpecifier: false } ]
30
31
  }
31
32
  }
32
33
  ]
package/typescript.js CHANGED
@@ -232,9 +232,9 @@ export default [
232
232
  '@typescript-eslint/prefer-function-type': 'error',
233
233
  '@typescript-eslint/unified-signatures': 'error',
234
234
  '@typescript-eslint/no-use-before-define': 'off',
235
- '@typescript-eslint/array-type': ['error', { default: 'array' }],
235
+ '@typescript-eslint/array-type': ['error', { default: 'array' } ],
236
236
  '@typescript-eslint/consistent-indexed-object-style': ['error', 'record'],
237
- '@typescript-eslint/consistent-type-assertions': ['error', { assertionStyle: 'as', objectLiteralTypeAssertions: 'allow' }],
237
+ '@typescript-eslint/consistent-type-assertions': ['error', { assertionStyle: 'as', objectLiteralTypeAssertions: 'allow' } ],
238
238
  '@typescript-eslint/consistent-type-definitions': ['error', 'interface'],
239
239
  '@typescript-eslint/method-signature-style': ['error', 'property'],
240
240
  '@typescript-eslint/no-empty-object-type': [
package/vue-typescript.js CHANGED
@@ -19,7 +19,11 @@ export default [
19
19
  }
20
20
  }),
21
21
 
22
- ...ConfigTypescript,
22
+ ...ConfigTypescript.map((config) => {
23
+ config.files = [...(config.files ?? []), ...EXTENSIONS_VUE]
24
+
25
+ return config
26
+ }),
23
27
 
24
28
  {
25
29
  name: 'cenk1cenk2/vue/typescript/recommended',