@pawover/kit-eslint-rules 0.1.0-alpha.1 → 0.1.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/index.d.ts CHANGED
@@ -1,5 +1,4 @@
1
1
  import { Linter } from "eslint";
2
- //#region src/config.d.ts
3
2
  /**
4
3
  * 预设工厂选项
5
4
  *
@@ -73,8 +72,6 @@ interface PawoverOptions {
73
72
  * ```
74
73
  */
75
74
  declare function pawover(options?: PawoverOptions): Linter.Config[];
76
- //#endregion
77
- //#region src/globExclude.d.ts
78
75
  /**
79
76
  * 全局忽略目录列表
80
77
  *
@@ -92,8 +89,6 @@ declare function pawover(options?: PawoverOptions): Linter.Config[];
92
89
  * ```
93
90
  */
94
91
  declare const GLOB_EXCLUDE: string[];
95
- //#endregion
96
- //#region src/index.d.ts
97
92
  /**
98
93
  * 规则严重级别(数字形式)
99
94
  *
@@ -142,5 +137,4 @@ export type Severity = SeverityName | SeverityLevel;
142
137
  * ```
143
138
  */
144
139
  export type RuleConfig<RuleOptions extends unknown[] = unknown[]> = Severity | [Severity, ...Partial<RuleOptions>];
145
- //#endregion
146
140
  export { GLOB_EXCLUDE, type PawoverOptions, pawover as default };
package/dist/index.js CHANGED
@@ -7,7 +7,7 @@ import simpleImportSort from "eslint-plugin-simple-import-sort";
7
7
  import vue from "eslint-plugin-vue";
8
8
  import vueEslintParser from "vue-eslint-parser";
9
9
  import typescriptEslint from "typescript-eslint";
10
- //#region src/preset.ts
10
+ // src/preset.ts
11
11
  /**
12
12
  * 预设配置
13
13
  *
@@ -96,8 +96,7 @@ var preset_default = {
96
96
  "method"
97
97
  ]
98
98
  };
99
- //#endregion
100
- //#region src/core.antfu.ts
99
+ // src/core.antfu.ts
101
100
  /**
102
101
  * `antfu` 规则组配置
103
102
  *
@@ -172,14 +171,19 @@ const rules$8 = {
172
171
  */
173
172
  "antfu/no-ts-export-equal": 2,
174
173
  /**
174
+ * @desc 强制复杂对象、数组与三元表达式换行
175
+ * @descEN Enforce multiline objects, arrays and ternaries when they are complex
176
+ * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/reasonable-newline.md
177
+ */
178
+ "antfu/reasonable-newline": 0,
179
+ /**
175
180
  * @desc 强制顶层函数使用 function 关键字声明
176
181
  * @descEN Enforce top-level functions to be declared with the `function` keyword
177
182
  * @see https://github.com/antfu/eslint-plugin-antfu/blob/main/src/rules/top-level-function.md
178
183
  */
179
184
  "antfu/top-level-function": 2
180
185
  };
181
- //#endregion
182
- //#region src/core.imports.ts
186
+ // src/core.imports.ts
183
187
  /**
184
188
  * `imports` 规则组配置
185
189
  *
@@ -241,8 +245,7 @@ const rules$7 = {
241
245
  */
242
246
  "imports/prefer-default-export": 0
243
247
  };
244
- //#endregion
245
- //#region src/core.importsSort.ts
248
+ // src/core.importsSort.ts
246
249
  /**
247
250
  * `importsSort` 规则组配置
248
251
  *
@@ -252,8 +255,7 @@ const rules$6 = {
252
255
  "importsSort/imports": 2,
253
256
  "importsSort/exports": 2
254
257
  };
255
- //#endregion
256
- //#region src/core.javascript.ts
258
+ // src/core.javascript.ts
257
259
  /**
258
260
  * `javascript` 规则组配置
259
261
  *
@@ -1482,8 +1484,7 @@ const rules$5 = {
1482
1484
  { onlyEquality: true }
1483
1485
  ]
1484
1486
  };
1485
- //#endregion
1486
- //#region src/core.react.ts
1487
+ // src/core.react.ts
1487
1488
  /**
1488
1489
  * `react` 规则组配置
1489
1490
  *
@@ -2013,8 +2014,7 @@ const rules$4 = {
2013
2014
  */
2014
2015
  "react/naming-convention-ref-name": 2
2015
2016
  };
2016
- //#endregion
2017
- //#region src/core.reactHooks.ts
2017
+ // src/core.reactHooks.ts
2018
2018
  /**
2019
2019
  * `reactHooks` 规则组配置
2020
2020
  *
@@ -2124,8 +2124,7 @@ const rules$3 = {
2124
2124
  */
2125
2125
  "react-hooks/use-memo": 0
2126
2126
  };
2127
- //#endregion
2128
- //#region src/core.stylistic.ts
2127
+ // src/core.stylistic.ts
2129
2128
  /**
2130
2129
  * `stylistic` 规则组配置
2131
2130
  *
@@ -2721,8 +2720,7 @@ const rules$2 = {
2721
2720
  */
2722
2721
  "stylistic/yield-star-spacing": 0
2723
2722
  };
2724
- //#endregion
2725
- //#region src/core.typescript.ts
2723
+ // src/core.typescript.ts
2726
2724
  /**
2727
2725
  * `typescript` 规则组配置
2728
2726
  *
@@ -3696,8 +3694,7 @@ const rules$1 = {
3696
3694
  */
3697
3695
  "ts/use-unknown-in-catch-callback-variable": 0
3698
3696
  };
3699
- //#endregion
3700
- //#region src/core.vue.ts
3697
+ // src/core.vue.ts
3701
3698
  /**
3702
3699
  * `vue` 规则组配置
3703
3700
  *
@@ -3889,6 +3886,8 @@ const rules = {
3889
3886
  "vue/next-tick-style": 0,
3890
3887
  "vue/no-bare-strings-in-template": 0,
3891
3888
  "vue/no-boolean-default": 0,
3889
+ "vue/no-content-outside-block": 2,
3890
+ "vue/no-define-model-default": 2,
3892
3891
  "vue/no-duplicate-attr-inheritance": 2,
3893
3892
  "vue/no-duplicate-class-names": 2,
3894
3893
  "vue/no-empty-component-block": 2,
@@ -3897,6 +3896,7 @@ const rules = {
3897
3896
  "vue/no-multiple-objects-in-class": 0,
3898
3897
  "vue/no-negated-v-if-condition": 0,
3899
3898
  "vue/no-potential-component-option-typo": 0,
3899
+ "vue/no-props-shadow": 2,
3900
3900
  "vue/no-ref-object-reactivity-loss": 0,
3901
3901
  "vue/no-restricted-block": 0,
3902
3902
  "vue/no-restricted-call-after-await": 0,
@@ -3911,6 +3911,7 @@ const rules = {
3911
3911
  "vue/no-restricted-v-on": 0,
3912
3912
  "vue/no-root-v-if": 0,
3913
3913
  "vue/no-setup-props-reactivity-loss": 0,
3914
+ "vue/no-shadow-native-events": 2,
3914
3915
  "vue/no-static-inline-styles": 0,
3915
3916
  "vue/no-template-target-blank": 0,
3916
3917
  "vue/no-this-in-before-route-enter": 2,
@@ -4016,8 +4017,7 @@ const rules = {
4016
4017
  "vue/space-unary-ops": 2,
4017
4018
  "vue/template-curly-spacing": 2
4018
4019
  };
4019
- //#endregion
4020
- //#region src/globExclude.ts
4020
+ // src/globExclude.ts
4021
4021
  /**
4022
4022
  * 全局忽略目录列表
4023
4023
  *
@@ -4068,8 +4068,7 @@ const GLOB_EXCLUDE = [
4068
4068
  "**/auto-component?(s).d.ts",
4069
4069
  "**/auto-router?(s).d.ts"
4070
4070
  ];
4071
- //#endregion
4072
- //#region src/plugins.ts
4071
+ // src/plugins.ts
4073
4072
  /**
4074
4073
  * 内嵌插件注册表
4075
4074
  *
@@ -4128,8 +4127,7 @@ const reactWithoutTypeChecked = {
4128
4127
  }))
4129
4128
  }
4130
4129
  };
4131
- //#endregion
4132
- //#region src/config.ts
4130
+ // src/config.ts
4133
4131
  const javascript = rules$5;
4134
4132
  const typescript = rules$1;
4135
4133
  const stylistic$1 = rules$2;
@@ -4284,8 +4282,6 @@ function pawover(options = {}) {
4284
4282
  });
4285
4283
  return configs;
4286
4284
  }
4287
- //#endregion
4288
- //#region src/index.ts
4285
+ // src/index.ts
4289
4286
  var src_default = pawover;
4290
- //#endregion
4291
4287
  export { GLOB_EXCLUDE, src_default as default };
package/package.json CHANGED
@@ -6,7 +6,7 @@
6
6
  "url": "https://github.com/pawover"
7
7
  },
8
8
  "description": "Self-contained ESLint flat config preset: javascript, typescript, react, vue, stylistic, antfu and import rules, with pinned bundled plugins",
9
- "version": "0.1.0-alpha.1",
9
+ "version": "0.1.0",
10
10
  "type": "module",
11
11
  "keywords": [
12
12
  "pawover",
@@ -19,7 +19,7 @@
19
19
  },
20
20
  "license": "MIT",
21
21
  "engines": {
22
- "node": ">=24.21.0"
22
+ "node": ">=24.22.2"
23
23
  },
24
24
  "main": "./dist/index.js",
25
25
  "module": "./dist/index.js",
@@ -44,14 +44,14 @@
44
44
  "access": "public"
45
45
  },
46
46
  "dependencies": {
47
- "@eslint-react/eslint-plugin": "5.26.1",
47
+ "@eslint-react/eslint-plugin": "5.28.8",
48
48
  "@stylistic/eslint-plugin": "6.0.0-beta.6",
49
- "eslint-plugin-antfu": "3.2.3",
49
+ "eslint-plugin-antfu": "3.3.1",
50
50
  "eslint-plugin-import-lite": "0.6.0",
51
51
  "eslint-plugin-react-hooks": "7.1.1",
52
- "eslint-plugin-simple-import-sort": "13.0.0",
53
- "eslint-plugin-vue": "10.10.0",
54
- "typescript-eslint": "8.71.1",
52
+ "eslint-plugin-simple-import-sort": "14.0.0",
53
+ "eslint-plugin-vue": "10.12.0",
54
+ "typescript-eslint": "8.72.1",
55
55
  "vue-eslint-parser": "10.4.1"
56
56
  },
57
57
  "devDependencies": {