@seahax/config-eslint 0.3.0 → 0.3.1
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/dist/index.js +15 -12
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -2,7 +2,7 @@ import path from 'node:path';
|
|
|
2
2
|
import js from '@eslint/js';
|
|
3
3
|
import stylistic from '@stylistic/eslint-plugin';
|
|
4
4
|
import { defineConfig } from 'eslint/config';
|
|
5
|
-
import
|
|
5
|
+
import prettierPluginRecommended from 'eslint-plugin-prettier/recommended';
|
|
6
6
|
import regexp from 'eslint-plugin-regexp';
|
|
7
7
|
import simpleImportSort from 'eslint-plugin-simple-import-sort';
|
|
8
8
|
import tseslint from 'typescript-eslint';
|
|
@@ -13,15 +13,7 @@ export default ({ indent = 2 } = {}) => {
|
|
|
13
13
|
rules: {
|
|
14
14
|
'no-undef': 'off',
|
|
15
15
|
},
|
|
16
|
-
},
|
|
17
|
-
commaDangle: 'always-multiline',
|
|
18
|
-
braceStyle: '1tbs',
|
|
19
|
-
indent,
|
|
20
|
-
quotes: 'single',
|
|
21
|
-
arrowParens: true,
|
|
22
|
-
semi: true,
|
|
23
|
-
severity: 'warn',
|
|
24
|
-
}), regexp.configs.recommended, tseslint.configs.recommended, tseslint.configs.stylistic, {
|
|
16
|
+
}, regexp.configs.recommended, tseslint.configs.recommended, tseslint.configs.stylistic, {
|
|
25
17
|
rules: {
|
|
26
18
|
'@typescript-eslint/ban-types': 'off',
|
|
27
19
|
'@typescript-eslint/no-empty-object-type': 'off',
|
|
@@ -36,11 +28,22 @@ export default ({ indent = 2 } = {}) => {
|
|
|
36
28
|
'simple-import-sort/imports': 'warn',
|
|
37
29
|
'simple-import-sort/exports': 'warn',
|
|
38
30
|
},
|
|
39
|
-
},
|
|
31
|
+
}, prettierPluginRecommended, {
|
|
40
32
|
rules: {
|
|
41
33
|
'prettier/prettier': 'warn',
|
|
42
34
|
},
|
|
43
|
-
}
|
|
35
|
+
},
|
|
36
|
+
// Intentionally added after prettier, but with rules that should
|
|
37
|
+
// be compatible with prettier
|
|
38
|
+
stylistic.configs.customize({
|
|
39
|
+
commaDangle: 'always-multiline',
|
|
40
|
+
braceStyle: '1tbs',
|
|
41
|
+
indent,
|
|
42
|
+
quotes: 'single',
|
|
43
|
+
arrowParens: true,
|
|
44
|
+
semi: true,
|
|
45
|
+
severity: 'warn',
|
|
46
|
+
}));
|
|
44
47
|
function progress() {
|
|
45
48
|
return {
|
|
46
49
|
plugins: {
|
package/package.json
CHANGED