vue-linters-config 0.3.6 → 0.3.8

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.
Files changed (3) hide show
  1. package/README.md +3 -21
  2. package/dist/index.js +27 -10
  3. package/package.json +1 -1
package/README.md CHANGED
@@ -34,7 +34,7 @@ import vueParser from 'vue-eslint-parser';
34
34
  import eslintPluginImportX from 'eslint-plugin-import-x';
35
35
  import eslintPluginPrettierRecommended from 'eslint-plugin-prettier/recommended';
36
36
  import globals from 'globals';
37
- import { ignores, settings, rules } from 'vue-linters-config';
37
+ import { parser, options, ignores, settings, rules } from 'vue-linters-config';
38
38
 
39
39
  export default tseslint.config(
40
40
  js.configs.recommended,
@@ -44,26 +44,8 @@ export default tseslint.config(
44
44
  eslintPluginImportX.flatConfigs.typescript,
45
45
 
46
46
  ignores,
47
-
48
- {
49
- files: ['**/*.{ts,tsx,vue}'],
50
- languageOptions: { parser: tseslint.parser },
51
- },
52
- {
53
- files: ['**/*.vue'],
54
- languageOptions: { parser: vueParser, parserOptions: { parser: tseslint.parser } },
55
- },
56
-
57
- {
58
- languageOptions: {
59
- ecmaVersion: 2022,
60
- sourceType: 'module',
61
- globals: { ...globals.browser, ...globals.node, ymaps: 'writable' },
62
- },
63
-
64
- ...settings,
65
- ...rules,
66
- },
47
+ parser(vueParser, tseslint.parser),
48
+ { ...options(globals), ...settings, ...rules },
67
49
 
68
50
  eslintPluginPrettierRecommended
69
51
  );
package/dist/index.js CHANGED
@@ -1,4 +1,19 @@
1
- const e = {
1
+ function o(e, r) {
2
+ return {
3
+ files: ["**/*.vue"],
4
+ languageOptions: { parser: e, parserOptions: { parser: r } }
5
+ };
6
+ }
7
+ function n(e) {
8
+ return {
9
+ languageOptions: {
10
+ ecmaVersion: 2022,
11
+ sourceType: "module",
12
+ globals: { ...e.browser, ...e.node, ymaps: "writable" }
13
+ }
14
+ };
15
+ }
16
+ const t = {
2
17
  ignores: [
3
18
  "**/dist/",
4
19
  "**/coverage/",
@@ -8,13 +23,13 @@ const e = {
8
23
  "**/package-lock.json",
9
24
  "**/android/"
10
25
  ]
11
- }, r = {
26
+ }, s = {
12
27
  settings: {
13
28
  "import-x/resolver": { node: { extensions: [".js", ".ts", ".mjs", ".d.ts"] } },
14
29
  "import-x/ignore": "vue",
15
30
  "import-x/external-module-folders": ["node_modules", "node_modules/@types"]
16
31
  }
17
- }, o = {
32
+ }, i = {
18
33
  rules: {
19
34
  "vue/attribute-hyphenation": ["error", "never", { ignore: ["hide-details"] }],
20
35
  "vue/block-lang": ["error", { script: { lang: "ts" } }],
@@ -225,7 +240,7 @@ const e = {
225
240
  }
226
241
  ]
227
242
  }
228
- }, t = {
243
+ }, a = {
229
244
  bracketSpacing: !0,
230
245
  jsxSingleQuote: !0,
231
246
  printWidth: 120,
@@ -235,7 +250,7 @@ const e = {
235
250
  trailingComma: "es5",
236
251
  useTabs: !1,
237
252
  bracketSameLine: !1
238
- }, n = {
253
+ }, l = {
239
254
  plugins: ["stylelint-prettier"],
240
255
  extends: [
241
256
  "stylelint-config-recommended-scss",
@@ -313,9 +328,11 @@ const e = {
313
328
  }
314
329
  };
315
330
  export {
316
- e as ignores,
317
- t as prettier,
318
- o as rules,
319
- r as settings,
320
- n as stylelint
331
+ t as ignores,
332
+ n as options,
333
+ o as parser,
334
+ a as prettier,
335
+ i as rules,
336
+ s as settings,
337
+ l as stylelint
321
338
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vue-linters-config",
3
- "version": "0.3.6",
3
+ "version": "0.3.8",
4
4
  "type": "module",
5
5
  "description": "Vue 3 linters config for eslint, prettier, stylelint",
6
6
  "author": "Aleksandr Dergunov <dergunovs@mail.ru>",