@dword-design/eslint-config 7.0.7 → 8.0.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.
- package/dist/create/index.js +39 -31
- package/package.json +9 -6
package/dist/create/index.js
CHANGED
|
@@ -2,6 +2,7 @@ import pathLib from "node:path";
|
|
|
2
2
|
import { fileURLToPath } from "node:url";
|
|
3
3
|
import importAlias from "@dword-design/eslint-plugin-import-alias";
|
|
4
4
|
import { FlatCompat } from "@eslint/eslintrc";
|
|
5
|
+
import stylistic from "@stylistic/eslint-plugin";
|
|
5
6
|
import confusingBrowserGlobals from "confusing-browser-globals";
|
|
6
7
|
import packageName from "depcheck-package-name";
|
|
7
8
|
import { defineConfig } from "eslint/config";
|
|
@@ -39,6 +40,9 @@ export default ({
|
|
|
39
40
|
files: ["**/*.ts", "**/*.vue"],
|
|
40
41
|
...plugin
|
|
41
42
|
})), {
|
|
43
|
+
files: ["**/*.ts", "**/*.vue"],
|
|
44
|
+
...stylistic.configs.recommended
|
|
45
|
+
}, {
|
|
42
46
|
files: ["**/*.ts", "**/*.vue"],
|
|
43
47
|
...importAlias.configs.recommended
|
|
44
48
|
}, {
|
|
@@ -84,6 +88,41 @@ export default ({
|
|
|
84
88
|
"@": "."
|
|
85
89
|
}
|
|
86
90
|
}],
|
|
91
|
+
"@stylistic/linebreak-style": ["error", "unix"],
|
|
92
|
+
"@stylistic/padding-line-between-statements": ["error", {
|
|
93
|
+
blankLine: "never",
|
|
94
|
+
next: "*",
|
|
95
|
+
prev: "*"
|
|
96
|
+
}, {
|
|
97
|
+
blankLine: "always",
|
|
98
|
+
next: "*",
|
|
99
|
+
prev: "import"
|
|
100
|
+
}, {
|
|
101
|
+
blankLine: "any",
|
|
102
|
+
next: "import",
|
|
103
|
+
prev: "import"
|
|
104
|
+
}, ...Object.keys({
|
|
105
|
+
"block-like": true,
|
|
106
|
+
const: true,
|
|
107
|
+
expression: true,
|
|
108
|
+
let: true
|
|
109
|
+
}).flatMap(name => [{
|
|
110
|
+
blankLine: "always",
|
|
111
|
+
next: `multiline-${name}`,
|
|
112
|
+
prev: "*"
|
|
113
|
+
}, {
|
|
114
|
+
blankLine: "always",
|
|
115
|
+
next: "*",
|
|
116
|
+
prev: `multiline-${name}`
|
|
117
|
+
}]), {
|
|
118
|
+
blankLine: "always",
|
|
119
|
+
next: "export",
|
|
120
|
+
prev: "*"
|
|
121
|
+
}, {
|
|
122
|
+
blankLine: "always",
|
|
123
|
+
next: "type",
|
|
124
|
+
prev: "*"
|
|
125
|
+
}],
|
|
87
126
|
"arrow-body-style": ["error", "as-needed"],
|
|
88
127
|
"func-names": ["error", "never"],
|
|
89
128
|
"global-require": "off",
|
|
@@ -95,7 +134,6 @@ export default ({
|
|
|
95
134
|
}],
|
|
96
135
|
"import-x/no-named-as-default": "off",
|
|
97
136
|
"import-x/no-named-as-default-member": "off",
|
|
98
|
-
"linebreak-style": ["error", "unix"],
|
|
99
137
|
"new-cap": "off",
|
|
100
138
|
"no-await-in-loop": "off",
|
|
101
139
|
"no-console": "off",
|
|
@@ -135,36 +173,6 @@ export default ({
|
|
|
135
173
|
trailingComma: "all"
|
|
136
174
|
}],
|
|
137
175
|
"object-shorthand": ["error", "always"],
|
|
138
|
-
"padding-line-between-statements": ["error", {
|
|
139
|
-
blankLine: "never",
|
|
140
|
-
next: "*",
|
|
141
|
-
prev: "*"
|
|
142
|
-
}, {
|
|
143
|
-
blankLine: "always",
|
|
144
|
-
next: "*",
|
|
145
|
-
prev: "import"
|
|
146
|
-
}, {
|
|
147
|
-
blankLine: "any",
|
|
148
|
-
next: "import",
|
|
149
|
-
prev: "import"
|
|
150
|
-
}, ...Object.keys({
|
|
151
|
-
"block-like": true,
|
|
152
|
-
const: true,
|
|
153
|
-
expression: true,
|
|
154
|
-
let: true
|
|
155
|
-
}).flatMap(name => [{
|
|
156
|
-
blankLine: "always",
|
|
157
|
-
next: `multiline-${name}`,
|
|
158
|
-
prev: "*"
|
|
159
|
-
}, {
|
|
160
|
-
blankLine: "always",
|
|
161
|
-
next: "*",
|
|
162
|
-
prev: `multiline-${name}`
|
|
163
|
-
}]), {
|
|
164
|
-
blankLine: "always",
|
|
165
|
-
next: "export",
|
|
166
|
-
prev: "*"
|
|
167
|
-
}],
|
|
168
176
|
"prefer-arrow/prefer-arrow-functions": ["error"],
|
|
169
177
|
"prefer-destructuring": "off",
|
|
170
178
|
"require-await": "error",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dword-design/eslint-config",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "8.0.0",
|
|
4
4
|
"repository": "dword-design/eslint-config",
|
|
5
5
|
"funding": "https://github.com/sponsors/dword-design",
|
|
6
6
|
"license": "MIT",
|
|
@@ -26,13 +26,16 @@
|
|
|
26
26
|
"lint": "base lint",
|
|
27
27
|
"prepare": "base prepare",
|
|
28
28
|
"prepublishOnly": "base prepublishOnly",
|
|
29
|
-
"test": "base test"
|
|
29
|
+
"test": "base test",
|
|
30
|
+
"typecheck": "base typecheck",
|
|
31
|
+
"verify": "base verify"
|
|
30
32
|
},
|
|
31
33
|
"dependencies": {
|
|
32
34
|
"@dword-design/eslint-plugin-import-alias": "^6.0.3",
|
|
33
35
|
"@eslint/eslintrc": "^3.3.1",
|
|
36
|
+
"@stylistic/eslint-plugin": "^5.2.0",
|
|
34
37
|
"confusing-browser-globals": "^1.0.11",
|
|
35
|
-
"depcheck-package-name": "^
|
|
38
|
+
"depcheck-package-name": "^4.0.0",
|
|
36
39
|
"eslint": "^9.29.0",
|
|
37
40
|
"eslint-config-flat-gitignore": "^2.1.0",
|
|
38
41
|
"eslint-config-prettier": "^10.1.5",
|
|
@@ -55,14 +58,14 @@
|
|
|
55
58
|
"typescript-eslint": "^8.34.1"
|
|
56
59
|
},
|
|
57
60
|
"devDependencies": {
|
|
58
|
-
"@dword-design/base": "^
|
|
61
|
+
"@dword-design/base": "^14.1.2",
|
|
59
62
|
"@playwright/test": "^1.53.1",
|
|
60
63
|
"endent": "npm:@dword-design/endent@^1.4.1",
|
|
61
|
-
"output-files": "^
|
|
64
|
+
"output-files": "^3.0.0"
|
|
62
65
|
},
|
|
63
66
|
"packageManager": "pnpm@10.11.0+sha512.6540583f41cc5f628eb3d9773ecee802f4f9ef9923cc45b69890fb47991d4b092964694ec3a4f738a420c918a333062c8b925d312f42e4f0c263eb603551f977",
|
|
64
67
|
"engines": {
|
|
65
|
-
"node": ">=
|
|
68
|
+
"node": ">=20"
|
|
66
69
|
},
|
|
67
70
|
"publishConfig": {
|
|
68
71
|
"access": "public"
|