@vida0905/eslint-config 2.4.1 → 2.4.3

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/cli/index.js CHANGED
@@ -6,7 +6,7 @@ import path from "node:path";
6
6
  import { green } from "ansis";
7
7
 
8
8
  //#region package.json
9
- var version = "2.4.1";
9
+ var version = "2.4.3";
10
10
 
11
11
  //#endregion
12
12
  //#region src/cli/constants.ts
package/dist/index.js CHANGED
@@ -42,6 +42,15 @@ const javascript = {
42
42
  //#endregion
43
43
  //#region src/overrides/stylistic.ts
44
44
  const stylistic = {
45
+ "style/indent": [
46
+ "error",
47
+ 2,
48
+ {
49
+ VariableDeclarator: "first",
50
+ offsetTernaryExpressions: true,
51
+ tabLength: 2
52
+ }
53
+ ],
45
54
  "style/quotes": [
46
55
  "error",
47
56
  "single",
@@ -76,8 +85,10 @@ function deepMerge(target, source) {
76
85
  //#endregion
77
86
  //#region src/index.ts
78
87
  function defineConfig(options = {}, ...userConfigs) {
79
- const configs = [deMorgan()];
80
- if (isPackageExists("nuxt")) configs.push(nuxt());
88
+ const { deMorgan: enableDeMorgan, nuxt: enableNuxt = isPackageExists("nuxt") } = options;
89
+ const configs = [];
90
+ if (enableDeMorgan) configs.push(deMorgan());
91
+ if (enableNuxt) configs.push(nuxt());
81
92
  const antfuConfig = {
82
93
  stylistic: {
83
94
  indent: 2,
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vida0905/eslint-config",
3
3
  "type": "module",
4
- "version": "2.4.1",
4
+ "version": "2.4.3",
5
5
  "description": "Vida Xie's ESLint Config",
6
6
  "author": "Vida Xie <vida_2020@163.com> (https://github.com/9romise/)",
7
7
  "license": "MIT",
@@ -36,7 +36,7 @@
36
36
  }
37
37
  },
38
38
  "dependencies": {
39
- "@antfu/eslint-config": "^4.14.1",
39
+ "@antfu/eslint-config": "^4.16.1",
40
40
  "ansis": "^4.1.0",
41
41
  "cac": "^6.7.14",
42
42
  "eslint-flat-config-utils": "^2.1.0",
@@ -44,13 +44,13 @@
44
44
  "local-pkg": "^1.1.1"
45
45
  },
46
46
  "devDependencies": {
47
- "@types/node": "^24.0.1",
48
- "eslint": "^9.28.0",
47
+ "@types/node": "^24.0.8",
48
+ "eslint": "^9.30.0",
49
49
  "eslint-typegen": "^2.2.0",
50
50
  "nano-staged": "^0.8.0",
51
51
  "simple-git-hooks": "^2.13.0",
52
- "tsdown": "^0.12.7",
53
- "tsx": "^4.20.1",
52
+ "tsdown": "^0.12.9",
53
+ "tsx": "^4.20.3",
54
54
  "typescript": "^5.8.3"
55
55
  },
56
56
  "simple-git-hooks": {
@@ -65,6 +65,7 @@
65
65
  "typegen": "tsx scripts/typegen",
66
66
  "typecheck": "tsc --noEmit",
67
67
  "lint": "eslint .",
68
- "check": "npm run typecheck && npm run lint"
68
+ "check": "npm run typecheck && npm run lint",
69
+ "inspect": "npx @eslint/config-inspector"
69
70
  }
70
71
  }