@alexlit/lint-kit 139.2.0 → 141.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.
Files changed (36) hide show
  1. package/package.json +2 -2
  2. package/packages/config-commitlint/package.json +1 -1
  3. package/packages/config-eslint/_legacy/package.json +1 -1
  4. package/packages/config-eslint/index.js +1 -0
  5. package/packages/config-eslint/node_modules/.bin/browserslist +4 -4
  6. package/packages/config-eslint/node_modules/.bin/eslint +2 -2
  7. package/packages/config-eslint/node_modules/.bin/eslint-config-prettier +2 -2
  8. package/packages/config-eslint/node_modules/.bin/tsc +2 -2
  9. package/packages/config-eslint/node_modules/.bin/tsserver +2 -2
  10. package/packages/config-eslint/package.json +30 -22
  11. package/packages/config-eslint/plugins/javascript.js +8 -3
  12. package/packages/config-eslint/plugins/jsdoc.js +7 -1
  13. package/packages/config-eslint/plugins/json.js +34 -0
  14. package/packages/config-eslint/plugins/perfectionist.js +7 -1
  15. package/packages/config-eslint/plugins/prettier.js +4 -2
  16. package/packages/config-eslint/plugins/regexp.js +3 -1
  17. package/packages/config-eslint/plugins/sonar.js +7 -1
  18. package/packages/config-eslint/plugins/stylistic.js +3 -0
  19. package/packages/config-eslint/plugins/tailwindcss.js +2 -0
  20. package/packages/config-eslint/plugins/typescript.js +3 -0
  21. package/packages/config-eslint/plugins/unicorn.js +7 -1
  22. package/packages/config-eslint/plugins/unocss.js +7 -1
  23. package/packages/config-eslint/plugins/vue-accessibility.js +1 -0
  24. package/packages/config-eslint/plugins/vue-i18n.js +7 -1
  25. package/packages/config-eslint/plugins/vue.js +5 -1
  26. package/packages/config-eslint/presets/_base.js +6 -4
  27. package/packages/config-eslint/presets/default.js +2 -0
  28. package/packages/config-hooks/lint-staged.js +4 -3
  29. package/packages/config-hooks/package.json +2 -2
  30. package/packages/config-htmllint/package.json +1 -1
  31. package/packages/config-markdownlint/package.json +1 -1
  32. package/packages/config-npmlint/package.json +1 -1
  33. package/packages/config-prettier/package.json +1 -1
  34. package/packages/config-stylelint/node_modules/.bin/browserslist +4 -4
  35. package/packages/config-stylelint/package.json +3 -3
  36. package/scripts/lint.eslint.sh +2 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alexlit/lint-kit",
3
- "version": "139.2.0",
3
+ "version": "141.0.0",
4
4
  "private": false,
5
5
  "description": "Preset of configuration files and dependencies for linting web applications (designed for Vue.js with TypeScript)",
6
6
  "keywords": [
@@ -31,7 +31,7 @@
31
31
  {
32
32
  "name": "Alexey Litovchenko",
33
33
  "email": "alex.lit@outlook.com",
34
- "url": "https://alexlit.gitlab.io"
34
+ "url": "https://github.com/alex-lit"
35
35
  }
36
36
  ],
37
37
  "type": "module",
@@ -19,7 +19,7 @@
19
19
  "license": "MIT",
20
20
  "author": "Alexey Litovchenko",
21
21
  "maintainers": [
22
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
22
+ "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)"
23
23
  ],
24
24
  "type": "module",
25
25
  "main": "index.js",
@@ -19,7 +19,7 @@
19
19
  "license": "MIT",
20
20
  "author": "Alexey Litovchenko",
21
21
  "maintainers": [
22
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
22
+ "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)"
23
23
  ],
24
24
  "type": "commonjs",
25
25
  "main": "index.js",
@@ -1,5 +1,6 @@
1
1
  export { javascript } from './plugins/javascript.js';
2
2
  export { jsdoc } from './plugins/jsdoc.js';
3
+ export { json } from './plugins/json.js';
3
4
  export { perfectionist } from './plugins/perfectionist.js';
4
5
  export { prettier, prettierConfig } from './plugins/prettier.js';
5
6
  export { regexp } from './plugins/regexp.js';
@@ -6,12 +6,12 @@ case `uname` in
6
6
  esac
7
7
 
8
8
  if [ -z "$NODE_PATH" ]; then
9
- export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.2/node_modules/browserslist/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.2/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules"
9
+ export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.4/node_modules/browserslist/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.4/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules"
10
10
  else
11
- export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.2/node_modules/browserslist/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.2/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules:$NODE_PATH"
11
+ export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.4/node_modules/browserslist/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.4/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
- exec "$basedir/node" "$basedir/../../../../node_modules/.pnpm/browserslist@4.24.2/node_modules/browserslist/cli.js" "$@"
14
+ exec "$basedir/node" "$basedir/../../../../node_modules/.pnpm/browserslist@4.24.4/node_modules/browserslist/cli.js" "$@"
15
15
  else
16
- exec node "$basedir/../../../../node_modules/.pnpm/browserslist@4.24.2/node_modules/browserslist/cli.js" "$@"
16
+ exec node "$basedir/../../../../node_modules/.pnpm/browserslist@4.24.4/node_modules/browserslist/cli.js" "$@"
17
17
  fi
@@ -11,7 +11,7 @@ else
11
11
  export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/eslint@9.20.1_jiti@2.4.2/node_modules/eslint/bin/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/eslint@9.20.1_jiti@2.4.2/node_modules/eslint/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/eslint@9.20.1_jiti@2.4.2/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
- exec "$basedir/node" "$basedir/../../../../node_modules/.pnpm/eslint@9.20.1_jiti@2.4.2/node_modules/eslint/bin/eslint.js" "$@"
14
+ exec "$basedir/node" "$basedir/../eslint/bin/eslint.js" "$@"
15
15
  else
16
- exec node "$basedir/../../../../node_modules/.pnpm/eslint@9.20.1_jiti@2.4.2/node_modules/eslint/bin/eslint.js" "$@"
16
+ exec node "$basedir/../eslint/bin/eslint.js" "$@"
17
17
  fi
@@ -11,7 +11,7 @@ else
11
11
  export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/eslint-config-prettier@10.0.1_eslint@9.20.1_jiti@2.4.2_/node_modules/eslint-config-prettier/build/bin/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/eslint-config-prettier@10.0.1_eslint@9.20.1_jiti@2.4.2_/node_modules/eslint-config-prettier/build/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/eslint-config-prettier@10.0.1_eslint@9.20.1_jiti@2.4.2_/node_modules/eslint-config-prettier/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/eslint-config-prettier@10.0.1_eslint@9.20.1_jiti@2.4.2_/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
- exec "$basedir/node" "$basedir/../../../../node_modules/.pnpm/eslint-config-prettier@10.0.1_eslint@9.20.1_jiti@2.4.2_/node_modules/eslint-config-prettier/build/bin/cli.js" "$@"
14
+ exec "$basedir/node" "$basedir/../eslint-config-prettier/build/bin/cli.js" "$@"
15
15
  else
16
- exec node "$basedir/../../../../node_modules/.pnpm/eslint-config-prettier@10.0.1_eslint@9.20.1_jiti@2.4.2_/node_modules/eslint-config-prettier/build/bin/cli.js" "$@"
16
+ exec node "$basedir/../eslint-config-prettier/build/bin/cli.js" "$@"
17
17
  fi
@@ -11,7 +11,7 @@ else
11
11
  export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/bin/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/typescript@5.7.3/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
- exec "$basedir/node" "$basedir/../../../../node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/bin/tsc" "$@"
14
+ exec "$basedir/node" "$basedir/../typescript/bin/tsc" "$@"
15
15
  else
16
- exec node "$basedir/../../../../node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/bin/tsc" "$@"
16
+ exec node "$basedir/../typescript/bin/tsc" "$@"
17
17
  fi
@@ -11,7 +11,7 @@ else
11
11
  export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/bin/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/typescript@5.7.3/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
- exec "$basedir/node" "$basedir/../../../../node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/bin/tsserver" "$@"
14
+ exec "$basedir/node" "$basedir/../typescript/bin/tsserver" "$@"
15
15
  else
16
- exec node "$basedir/../../../../node_modules/.pnpm/typescript@5.7.3/node_modules/typescript/bin/tsserver" "$@"
16
+ exec node "$basedir/../typescript/bin/tsserver" "$@"
17
17
  fi
@@ -1,48 +1,50 @@
1
1
  {
2
2
  "name": "@alexlit/config-eslint",
3
- "version": "102.6.0",
3
+ "version": "105.0.1",
4
4
  "private": false,
5
- "description": "Eslint config",
5
+ "description": "Sharable ESLint configuration",
6
6
  "keywords": [
7
7
  "eslint",
8
- "config"
8
+ "eslint-config",
9
+ "lint",
10
+ "code-quality",
11
+ "javascript",
12
+ "typescript"
9
13
  ],
10
- "homepage": "https://github.com/alex-lit/lint-kit#readme",
14
+ "homepage": "https://github.com/alex-lit/lint-kit/tree/main/packages/config-eslint#readme",
11
15
  "bugs": {
12
16
  "url": "https://github.com/alex-lit/lint-kit/issues"
13
17
  },
14
18
  "repository": {
15
19
  "type": "git",
16
- "url": "https://github.com/alex-lit/lint-kit.git",
20
+ "url": "git+https://github.com/alex-lit/lint-kit.git",
17
21
  "directory": "packages/config-eslint"
18
22
  },
19
23
  "license": "MIT",
20
- "author": "Alexey Litovchenko",
21
- "maintainers": [
22
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
23
- ],
24
+ "author": "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)",
24
25
  "type": "module",
25
- "main": "index.js",
26
+ "main": "./index.js",
26
27
  "files": [
27
- "README.md",
28
28
  "index.js",
29
- "plugins",
30
- "presets"
29
+ "plugins/",
30
+ "presets/",
31
+ "README.md"
31
32
  ],
32
33
  "scripts": {
33
34
  "inspect": "npx @eslint/config-inspector@latest",
34
35
  "lint": "cd ../../ && ./scripts/lint.eslint.sh",
35
- "ou": "../../scripts/ou.sh --local",
36
- "release": "../../scripts/release.sh",
37
- "semver": "../../scripts/semver.sh",
38
- "up": "../../scripts/up.sh --local"
36
+ "ou": "sh ../../scripts/ou.sh --local",
37
+ "release": "sh ../../scripts/release.sh",
38
+ "semver": "sh ../../scripts/semver.sh",
39
+ "up": "sh ../../scripts/up.sh --local"
39
40
  },
40
41
  "dependencies": {
41
42
  "@eslint/js": "^9.20.0",
43
+ "@eslint/json": "^0.10.0",
42
44
  "@intlify/eslint-plugin-vue-i18n": "^3.2.0",
43
- "@stylistic/eslint-plugin": "^3.1.0",
45
+ "@stylistic/eslint-plugin": "^4.0.1",
44
46
  "@tanstack/eslint-plugin-query": "^5.66.1",
45
- "@unocss/eslint-config": "^65.5.0",
47
+ "@unocss/eslint-config": "^66.0.0",
46
48
  "eslint": "9.20.1",
47
49
  "eslint-config-prettier": "^10.0.1",
48
50
  "eslint-plugin-jsdoc": "^50.6.3",
@@ -51,15 +53,21 @@
51
53
  "eslint-plugin-regexp": "^2.7.0",
52
54
  "eslint-plugin-sonarjs": "^3.0.2",
53
55
  "eslint-plugin-tailwindcss": "^3.18.0",
54
- "eslint-plugin-unicorn": "^56.0.1",
56
+ "eslint-plugin-unicorn": "^57.0.0",
55
57
  "eslint-plugin-vitest": "^0.5.4",
56
58
  "eslint-plugin-vue": "^9.32.0",
57
59
  "eslint-plugin-vuejs-accessibility": "^2.4.1",
58
60
  "globals": "^15.15.0",
59
61
  "typescript": "^5.7.3",
60
- "typescript-eslint": "^8.24.0"
62
+ "typescript-eslint": "^8.24.1"
61
63
  },
64
+ "packageManager": "pnpm@9.x",
62
65
  "engines": {
63
- "node": ">=18.18"
66
+ "node": ">=18.18",
67
+ "pnpm": ">=9"
68
+ },
69
+ "publishConfig": {
70
+ "access": "public",
71
+ "registry": "https://registry.npmjs.org/"
64
72
  }
65
73
  }
@@ -1,12 +1,17 @@
1
1
  import plugin from '@eslint/js';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [eslint](https://eslint.org) */
4
6
  export const javascript = [
5
- plugin.configs.recommended,
6
-
7
7
  {
8
+ files: FILES,
9
+ ...plugin.configs.recommended,
10
+ },
11
+ {
12
+ files: FILES,
8
13
  rules: {
9
- curly: 'error',
14
+ 'curly': 'error',
10
15
  'dot-notation': ['error'],
11
16
  'func-style': ['error', 'declaration', { allowArrowFunctions: true }],
12
17
  'grouped-accessor-pairs': ['error', 'getBeforeSet'],
@@ -1,9 +1,15 @@
1
1
  import plugin from 'eslint-plugin-jsdoc';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [eslint-plugin-jsdoc](https://github.com/gajus/eslint-plugin-jsdoc) */
4
6
  export const jsdoc = [
5
- plugin.configs['flat/recommended'],
6
7
  {
8
+ files: FILES,
9
+ ...plugin.configs['flat/recommended'],
10
+ },
11
+ {
12
+ files: FILES,
7
13
  rules: {
8
14
  'jsdoc/lines-before-block': 'off',
9
15
  'jsdoc/no-undefined-types': 'off',
@@ -0,0 +1,34 @@
1
+ import plugin from '@eslint/json';
2
+
3
+ /** @see [eslint/json](https://github.com/eslint/json) */
4
+ export const json = [
5
+ // json
6
+ {
7
+ files: ['**/*.json'],
8
+ ignores: ['**/package-lock.json'],
9
+ language: 'json/json',
10
+ ...plugin.configs.recommended,
11
+ },
12
+ {
13
+ files: ['**/*.json'],
14
+ ignores: ['**/package.json', '**/package-lock.json'],
15
+ rules: {
16
+ 'json/sort-keys': 'warn',
17
+ 'json/top-level-interop': 'error',
18
+ },
19
+ },
20
+
21
+ // jsonc
22
+ {
23
+ files: ['**/*.jsonc'],
24
+ language: 'json/jsonc',
25
+ ...plugin.configs.recommended,
26
+ },
27
+
28
+ // json5
29
+ {
30
+ files: ['**/*.json5'],
31
+ language: 'json/json5',
32
+ ...plugin.configs.recommended,
33
+ },
34
+ ];
@@ -1,9 +1,15 @@
1
1
  import plugin from 'eslint-plugin-perfectionist';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [eslint-plugin-perfectionist](https://perfectionist.dev) */
4
6
  export const perfectionist = [
5
- plugin.configs['recommended-natural'],
6
7
  {
8
+ files: FILES,
9
+ ...plugin.configs['recommended-natural'],
10
+ },
11
+ {
12
+ files: FILES,
7
13
  rules: {
8
14
  'perfectionist/sort-imports': [
9
15
  'warn',
@@ -1,6 +1,8 @@
1
1
  import config from 'eslint-config-prettier';
2
2
  import plugin from 'eslint-plugin-prettier/recommended';
3
3
 
4
+ import { FILES } from '../presets/_base.js';
5
+
4
6
  const fixes = {
5
7
  // fix for prettier/vue
6
8
  'vue/html-self-closing': [
@@ -19,7 +21,7 @@ const fixes = {
19
21
 
20
22
  /** @see [eslint-plugin-prettier](https://github.com/prettier/eslint-plugin-prettier) */
21
23
  export const prettier = [
22
- plugin,
24
+ { files: FILES, ...plugin },
23
25
  {
24
26
  files: ['**/*.vue'],
25
27
  rules: { ...fixes },
@@ -28,7 +30,7 @@ export const prettier = [
28
30
 
29
31
  /** @see [eslint-config-prettier](https://github.com/prettier/eslint-config-prettier) */
30
32
  export const prettierConfig = [
31
- config,
33
+ { files: FILES, ...config },
32
34
  {
33
35
  files: ['**/*.vue'],
34
36
  rules: { ...fixes },
@@ -1,4 +1,6 @@
1
1
  import plugin from 'eslint-plugin-regexp';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [eslint-plugin-regexp](https://github.com/ota-meshi/eslint-plugin-regexp) */
4
- export const regexp = [plugin.configs['flat/recommended']];
6
+ export const regexp = [{ files: FILES, ...plugin.configs['flat/recommended'] }];
@@ -1,9 +1,15 @@
1
1
  import plugin from 'eslint-plugin-sonarjs';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [eslint-plugin-sonarjs](https://github.com/SonarSource/eslint-plugin-sonarjs) */
4
6
  export const sonar = [
5
- plugin.configs.recommended,
6
7
  {
8
+ files: FILES,
9
+ ...plugin.configs.recommended,
10
+ },
11
+ {
12
+ files: FILES,
7
13
  plugins: {
8
14
  sonar: plugin,
9
15
  },
@@ -1,8 +1,11 @@
1
1
  import plugin from '@stylistic/eslint-plugin';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [@stylistic/eslint-plugin](https://eslint.style/) */
4
6
  export const stylistic = [
5
7
  {
8
+ files: FILES,
6
9
  plugins: {
7
10
  '@stylistic': plugin,
8
11
  },
@@ -1,10 +1,12 @@
1
1
  // import tailwind from 'eslint-plugin-tailwindcss';
2
+ import { FILES } from '../presets/_base.js';
2
3
 
3
4
  /** @see [eslint-plugin-tailwindcss](https://github.com/francoismassart/eslint-plugin-tailwindcss) */
4
5
  export const tailwindcss = [
5
6
  // TODO: включить после обновления плагина
6
7
  // ...tailwind.configs['flat/recommended'],
7
8
  {
9
+ files: FILES,
8
10
  rules: {
9
11
  // 'tailwindcss/no-custom-classname': 'off',
10
12
  'vue/static-class-names-order': 'off',
@@ -1,11 +1,14 @@
1
1
  import plugin from 'typescript-eslint';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [typescript-eslint](https://github.com/typescript-eslint/typescript-eslint) */
4
6
  export const typescript = [
5
7
  ...plugin.configs.strict,
6
8
  ...plugin.configs.stylistic,
7
9
 
8
10
  {
11
+ files: FILES,
9
12
  rules: {
10
13
  '@typescript-eslint/no-explicit-any': 'warn',
11
14
  },
@@ -1,9 +1,15 @@
1
1
  import plugin from 'eslint-plugin-unicorn';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [eslint-plugin-unicorn](https://github.com/sindresorhus/eslint-plugin-unicorn) */
4
6
  export const unicorn = [
5
- plugin.configs['flat/all'],
6
7
  {
8
+ files: FILES,
9
+ ...plugin.configs['flat/all'],
10
+ },
11
+ {
12
+ files: FILES,
7
13
  rules: {
8
14
  'unicorn/better-regex': 'off',
9
15
  'unicorn/consistent-destructuring': 'warn',
@@ -1,9 +1,15 @@
1
1
  import plugin from '@unocss/eslint-config/flat';
2
2
 
3
+ import { FILES } from '../presets/_base.js';
4
+
3
5
  /** @see [@unocss/eslint-config](https://unocss.dev/integrations/eslint) */
4
6
  export const unocss = [
5
- plugin,
6
7
  {
8
+ files: FILES,
9
+ ...plugin,
10
+ },
11
+ {
12
+ files: FILES,
7
13
  rules: {
8
14
  'unocss/order-attributify': 'off',
9
15
  },
@@ -3,6 +3,7 @@ import plugin from 'eslint-plugin-vuejs-accessibility';
3
3
  /** @see [eslint-plugin-vuejs-accessibility](https://vue-a11y.github.io/eslint-plugin-vuejs-accessibility/) */
4
4
  export const vueAccessibility = [
5
5
  ...plugin.configs['flat/recommended'],
6
+
6
7
  {
7
8
  files: ['**/*.vue'],
8
9
  rules: {
@@ -2,7 +2,11 @@ import plugin from '@intlify/eslint-plugin-vue-i18n';
2
2
 
3
3
  /** @see [eslint-plugin-vue-i18n](https://eslint-plugin-vue-i18n.intlify.dev/) */
4
4
  export const vueI18n = [
5
- ...plugin.configs['flat/recommended'],
5
+ ...plugin.configs['flat/recommended'].map((config) => ({
6
+ ...config,
7
+ files: ['**/*.vue'],
8
+ })),
9
+
6
10
  {
7
11
  files: ['**/*.vue'],
8
12
  rules: {
@@ -24,6 +28,8 @@ export const vueI18n = [
24
28
  '@intlify/vue-i18n/no-unused-keys': 'warn',
25
29
  '@intlify/vue-i18n/prefer-sfc-lang-attr': 'error',
26
30
  },
31
+ },
32
+ {
27
33
  settings: {
28
34
  'vue-i18n': {
29
35
  localeDir: './**/locales/*.{json,json5,yaml,yml}',
@@ -3,7 +3,11 @@ import typescript from 'typescript-eslint';
3
3
 
4
4
  /** @see [eslint-plugin-vue](https://eslint.vuejs.org/rules/) */
5
5
  export const vue = [
6
- ...plugin.configs['flat/recommended'],
6
+ ...plugin.configs['flat/recommended'].map((config) => ({
7
+ ...config,
8
+ files: ['**/*.vue'],
9
+ })),
10
+
7
11
  {
8
12
  files: ['**/*.vue'],
9
13
  languageOptions: { parserOptions: { parser: typescript.parser } },
@@ -1,11 +1,15 @@
1
1
  import globals from 'globals';
2
2
 
3
+ export const FILES = ['**/*.{js,mjs,cjs,typescript,vue}'];
4
+
3
5
  /** Base config */
4
6
  export const _base = [
5
7
  {
6
- files: ['**/*.{js,mjs,cjs,typescript,vue}'],
8
+ files: FILES,
9
+ languageOptions: {
10
+ globals: globals.browser,
11
+ },
7
12
  },
8
-
9
13
  {
10
14
  ignores: [
11
15
  '**/.temp',
@@ -19,6 +23,4 @@ export const _base = [
19
23
  'sw.js',
20
24
  ],
21
25
  },
22
-
23
- { languageOptions: { globals: globals.browser } },
24
26
  ];
@@ -1,5 +1,6 @@
1
1
  import { javascript } from '../plugins/javascript.js';
2
2
  import { jsdoc } from '../plugins/jsdoc.js';
3
+ import { json } from '../plugins/json.js';
3
4
  import { perfectionist } from '../plugins/perfectionist.js';
4
5
  import { prettierConfig } from '../plugins/prettier.js';
5
6
  import { regexp } from '../plugins/regexp.js';
@@ -19,6 +20,7 @@ export const defaultPreset = [
19
20
 
20
21
  ...javascript,
21
22
  ...jsdoc,
23
+ ...json,
22
24
  ...perfectionist,
23
25
  ...regexp,
24
26
  ...sonar,
@@ -31,7 +31,7 @@ const createLintStagedConfig = (plugins = {}, config = {}) => {
31
31
 
32
32
  const markdownlint = pluginsList.markdownlint
33
33
  ? 'markdownlint --fix'
34
- : 'markdownlint "eslint disabled"';
34
+ : 'echo "markdownlint disabled"';
35
35
 
36
36
  const npmlint = pluginsList.npmlint
37
37
  ? 'npmPkgJsonLint'
@@ -52,8 +52,9 @@ const createLintStagedConfig = (plugins = {}, config = {}) => {
52
52
  '*.html': [htmllint, prettier],
53
53
  '*.jade': [prettier],
54
54
  '*.js': [eslint, prettier],
55
- '*.json,!package-lock.json': [prettier],
56
- '*.jsonc': [prettier],
55
+ '*.json5': [prettier, eslint],
56
+ '*.json,!package-lock.json': [eslint, prettier],
57
+ '*.jsonc': [prettier, eslint],
57
58
  '*.jsonp': [prettier],
58
59
  '*.jsx': [eslint, prettier],
59
60
  '*.md': [prettier, markdownlint],
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alexlit/config-hooks",
3
- "version": "4.4.3",
3
+ "version": "4.5.0",
4
4
  "private": false,
5
5
  "description": "Hooks config",
6
6
  "keywords": [
@@ -19,7 +19,7 @@
19
19
  "license": "MIT",
20
20
  "author": "Alexey Litovchenko",
21
21
  "maintainers": [
22
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
22
+ "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)"
23
23
  ],
24
24
  "type": "module",
25
25
  "main": "index.js",
@@ -21,7 +21,7 @@
21
21
  "license": "MIT",
22
22
  "author": "Alexey Litovchenko",
23
23
  "maintainers": [
24
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
24
+ "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)"
25
25
  ],
26
26
  "type": "module",
27
27
  "main": "index.js",
@@ -19,7 +19,7 @@
19
19
  "license": "MIT",
20
20
  "author": "Alexey Litovchenko",
21
21
  "maintainers": [
22
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
22
+ "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)"
23
23
  ],
24
24
  "main": "index.json",
25
25
  "files": [
@@ -23,7 +23,7 @@
23
23
  "license": "MIT",
24
24
  "author": "Alexey Litovchenko",
25
25
  "maintainers": [
26
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
26
+ "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)"
27
27
  ],
28
28
  "main": "index.json",
29
29
  "files": [
@@ -19,7 +19,7 @@
19
19
  "license": "MIT",
20
20
  "author": "Alexey Litovchenko",
21
21
  "maintainers": [
22
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
22
+ "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)"
23
23
  ],
24
24
  "type": "module",
25
25
  "main": "index.js",
@@ -6,12 +6,12 @@ case `uname` in
6
6
  esac
7
7
 
8
8
  if [ -z "$NODE_PATH" ]; then
9
- export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.4/node_modules/browserslist/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.4/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules"
9
+ export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.2/node_modules/browserslist/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.2/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules"
10
10
  else
11
- export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.4/node_modules/browserslist/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.4/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules:$NODE_PATH"
11
+ export NODE_PATH="/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.2/node_modules/browserslist/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/browserslist@4.24.2/node_modules:/home/alexlit/Work/@alexlit/lint-kit/node_modules/.pnpm/node_modules:$NODE_PATH"
12
12
  fi
13
13
  if [ -x "$basedir/node" ]; then
14
- exec "$basedir/node" "$basedir/../../../../node_modules/.pnpm/browserslist@4.24.4/node_modules/browserslist/cli.js" "$@"
14
+ exec "$basedir/node" "$basedir/../../../../node_modules/.pnpm/browserslist@4.24.2/node_modules/browserslist/cli.js" "$@"
15
15
  else
16
- exec node "$basedir/../../../../node_modules/.pnpm/browserslist@4.24.4/node_modules/browserslist/cli.js" "$@"
16
+ exec node "$basedir/../../../../node_modules/.pnpm/browserslist@4.24.2/node_modules/browserslist/cli.js" "$@"
17
17
  fi
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alexlit/config-stylelint",
3
- "version": "50.0.1",
3
+ "version": "50.0.2",
4
4
  "private": false,
5
5
  "description": "Stylelint config",
6
6
  "keywords": [
@@ -19,7 +19,7 @@
19
19
  "license": "MIT",
20
20
  "author": "Alexey Litovchenko",
21
21
  "maintainers": [
22
- "Alexey Litovchenko <alex.lit@outlook.com> (https://alexlit.gitlab.io)"
22
+ "Alexey Litovchenko <alex.lit@outlook.com> (https://github.com/alex-lit)"
23
23
  ],
24
24
  "type": "module",
25
25
  "main": "index.js",
@@ -37,7 +37,7 @@
37
37
  },
38
38
  "dependencies": {
39
39
  "@double-great/stylelint-a11y": "^3.0.4",
40
- "postcss": "^8.5.2",
40
+ "postcss": "^8.5.3",
41
41
  "postcss-html": "^1.8.0",
42
42
  "prettier": "^3.5.1",
43
43
  "stylelint": "16.14.1",
@@ -4,7 +4,7 @@ source "$(dirname $0)"/../bash.config.sh
4
4
 
5
5
  OPTION=${1}
6
6
 
7
- FILES='.cjs,.mjs,.js,.jsx,.ts,.tsx,.vue'
7
+ FILES='./**/*{.cjs,.mjs,.js,.jsx,.ts,.tsx,.json,.jsonc,.json5,.vue}'
8
8
 
9
9
  echo -e "${YELLOW}eslint ${GREY}-> ${CYAN}${FILES}${WHITE}"
10
10
 
@@ -12,4 +12,4 @@ if [ $OPTION ] && [ $OPTION = 'fix' ]; then
12
12
  echo -e "${GREY}autofix:${WHITE} true"
13
13
  fi
14
14
 
15
- eslint ./**/*{${FILES}} --${OPTION}
15
+ eslint ${FILES} --${OPTION}