@html-validate/eslint-config-vue 5.27.0 → 5.29.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/index.mjs +37 -0
- package/package.json +6 -4
- /package/{index.js → legacy.cjs} +0 -0
package/index.mjs
ADDED
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import eslintConfigPrettier from "eslint-config-prettier";
|
|
2
|
+
import eslintPluginVue from "eslint-plugin-vue";
|
|
3
|
+
|
|
4
|
+
function filterRules(rules, predicate) {
|
|
5
|
+
return Object.fromEntries(Object.entries(rules).filter(([key]) => predicate(key)));
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* @typedef {import("eslint").Linter.Config} Config
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* @param {Config} config
|
|
14
|
+
* @returns {Config}
|
|
15
|
+
*/
|
|
16
|
+
function defineConfig(config) {
|
|
17
|
+
return config;
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
const recommended = eslintPluginVue.configs["flat/recommended"][1];
|
|
21
|
+
|
|
22
|
+
export default defineConfig({
|
|
23
|
+
languageOptions: {
|
|
24
|
+
parser: recommended.languageOptions.parser,
|
|
25
|
+
},
|
|
26
|
+
|
|
27
|
+
processor: eslintPluginVue.processors.vue,
|
|
28
|
+
|
|
29
|
+
plugins: {
|
|
30
|
+
vue: eslintPluginVue,
|
|
31
|
+
},
|
|
32
|
+
|
|
33
|
+
rules: {
|
|
34
|
+
...recommended.rules,
|
|
35
|
+
...filterRules(eslintConfigPrettier.rules, (rule) => rule.startsWith("vue/")),
|
|
36
|
+
},
|
|
37
|
+
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@html-validate/eslint-config-vue",
|
|
3
|
-
"version": "5.
|
|
3
|
+
"version": "5.29.0",
|
|
4
4
|
"description": "Eslint sharable config used by the various HTML-validate packages",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eslint",
|
|
@@ -17,9 +17,10 @@
|
|
|
17
17
|
},
|
|
18
18
|
"license": "MIT",
|
|
19
19
|
"author": "David Sveningsson <ext@sidvind.com>",
|
|
20
|
-
"main": "index.
|
|
20
|
+
"main": "index.mjs",
|
|
21
21
|
"files": [
|
|
22
|
-
"*.
|
|
22
|
+
"*.cjs",
|
|
23
|
+
"*.mjs"
|
|
23
24
|
],
|
|
24
25
|
"scripts": {
|
|
25
26
|
"prepack": "release-prepack --retain-scripts",
|
|
@@ -27,6 +28,7 @@
|
|
|
27
28
|
"prepublishOnly": "release-prepublish --retain-scripts"
|
|
28
29
|
},
|
|
29
30
|
"dependencies": {
|
|
31
|
+
"eslint-config-prettier": "10.1.1",
|
|
30
32
|
"eslint-plugin-vue": "10.0.0"
|
|
31
33
|
},
|
|
32
34
|
"peerDependencies": {
|
|
@@ -39,5 +41,5 @@
|
|
|
39
41
|
"publishConfig": {
|
|
40
42
|
"access": "public"
|
|
41
43
|
},
|
|
42
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "ca95247b7c60f1ba1a30795bece5fa762670d917"
|
|
43
45
|
}
|
/package/{index.js → legacy.cjs}
RENAMED
|
File without changes
|