@sxzz/eslint-config 7.1.2 → 7.1.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/LICENSE +1 -1
- package/README.md +15 -2
- package/dist/index.d.ts +19 -6
- package/package.json +18 -17
package/LICENSE
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
The MIT License (MIT)
|
|
2
2
|
|
|
3
|
-
Copyright © 2021-PRESENT
|
|
3
|
+
Copyright © 2021-PRESENT Kevin Deng (https://github.com/sxzz)
|
|
4
4
|
|
|
5
5
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
6
|
of this software and associated documentation files (the "Software"), to deal
|
package/README.md
CHANGED
|
@@ -1,4 +1,8 @@
|
|
|
1
|
-
# @sxzz/eslint-config
|
|
1
|
+
# @sxzz/eslint-config
|
|
2
|
+
|
|
3
|
+
[![npm version][npm-version-src]][npm-version-href]
|
|
4
|
+
[![npm downloads][npm-downloads-src]][npm-downloads-href]
|
|
5
|
+
[![Unit Test][unit-test-src]][unit-test-href]
|
|
2
6
|
|
|
3
7
|
A opinionated ESLint config preset for JavaScript, TypeScript, Vue,
|
|
4
8
|
and Prettier.
|
|
@@ -82,4 +86,13 @@ Most of the rules are the same, but there are some differences:
|
|
|
82
86
|
|
|
83
87
|
## License
|
|
84
88
|
|
|
85
|
-
[MIT](./LICENSE) License © 2021-PRESENT [
|
|
89
|
+
[MIT](./LICENSE) License © 2021-PRESENT [Kevin Deng](https://github.com/sxzz)
|
|
90
|
+
|
|
91
|
+
<!-- Badges -->
|
|
92
|
+
|
|
93
|
+
[npm-version-src]: https://img.shields.io/npm/v/@sxzz/eslint-config.svg
|
|
94
|
+
[npm-version-href]: https://npmjs.com/package/@sxzz/eslint-config
|
|
95
|
+
[npm-downloads-src]: https://img.shields.io/npm/dm/@sxzz/eslint-config
|
|
96
|
+
[npm-downloads-href]: https://www.npmcharts.com/compare/@sxzz/eslint-config?interval=30
|
|
97
|
+
[unit-test-src]: https://github.com/sxzz/eslint-config/actions/workflows/unit-test.yml/badge.svg
|
|
98
|
+
[unit-test-href]: https://github.com/sxzz/eslint-config/actions/workflows/unit-test.yml
|
package/dist/index.d.ts
CHANGED
|
@@ -3242,7 +3242,7 @@ interface Rules {
|
|
|
3242
3242
|
*/
|
|
3243
3243
|
"pnpm/json-enforce-catalog"?: Linter.RuleEntry<PnpmJsonEnforceCatalog>;
|
|
3244
3244
|
/**
|
|
3245
|
-
* Prefer having pnpm settings in `pnpm-workspace.yaml` instead of `package.json`. This
|
|
3245
|
+
* Prefer having pnpm settings in `pnpm-workspace.yaml` instead of `package.json`. This requires pnpm v10.6+, see https://github.com/orgs/pnpm/discussions/9037.
|
|
3246
3246
|
* @see https://github.com/antfu/pnpm-workspace-utils/tree/main/packages/eslint-plugin-pnpm/src/rules/json/json-prefer-workspace-settings.test.ts
|
|
3247
3247
|
*/
|
|
3248
3248
|
"pnpm/json-prefer-workspace-settings"?: Linter.RuleEntry<PnpmJsonPreferWorkspaceSettings>;
|
|
@@ -3252,7 +3252,7 @@ interface Rules {
|
|
|
3252
3252
|
*/
|
|
3253
3253
|
"pnpm/json-valid-catalog"?: Linter.RuleEntry<PnpmJsonValidCatalog>;
|
|
3254
3254
|
/**
|
|
3255
|
-
* Disallow
|
|
3255
|
+
* Disallow duplicate catalog items in `pnpm-workspace.yaml`
|
|
3256
3256
|
* @see https://github.com/antfu/pnpm-workspace-utils/tree/main/packages/eslint-plugin-pnpm/src/rules/yaml/yaml-no-duplicate-catalog-item.test.ts
|
|
3257
3257
|
*/
|
|
3258
3258
|
"pnpm/yaml-no-duplicate-catalog-item"?: Linter.RuleEntry<PnpmYamlNoDuplicateCatalogItem>;
|
|
@@ -4593,7 +4593,7 @@ interface Rules {
|
|
|
4593
4593
|
* Order of UnoCSS utilities in class attribute
|
|
4594
4594
|
* @see https://unocss.dev/integrations/eslint#rules
|
|
4595
4595
|
*/
|
|
4596
|
-
"unocss/order"?: Linter.RuleEntry<
|
|
4596
|
+
"unocss/order"?: Linter.RuleEntry<UnocssOrder>;
|
|
4597
4597
|
/**
|
|
4598
4598
|
* Order of UnoCSS attributes
|
|
4599
4599
|
* @see https://unocss.dev/integrations/eslint#rules
|
|
@@ -7512,10 +7512,17 @@ type NoRestrictedExports = [] | [({
|
|
|
7512
7512
|
namespaceFrom?: boolean;
|
|
7513
7513
|
};
|
|
7514
7514
|
})];
|
|
7515
|
-
type NoRestrictedGlobals = (string | {
|
|
7515
|
+
type NoRestrictedGlobals = ((string | {
|
|
7516
7516
|
name: string;
|
|
7517
7517
|
message?: string;
|
|
7518
|
-
})[]
|
|
7518
|
+
})[] | [] | [{
|
|
7519
|
+
globals: (string | {
|
|
7520
|
+
name: string;
|
|
7521
|
+
message?: string;
|
|
7522
|
+
})[];
|
|
7523
|
+
checkGlobalObject?: boolean;
|
|
7524
|
+
globalObjects?: string[];
|
|
7525
|
+
}]);
|
|
7519
7526
|
type NoRestrictedImports = ((string | {
|
|
7520
7527
|
name: string;
|
|
7521
7528
|
message?: string;
|
|
@@ -7946,6 +7953,8 @@ type OneVar = [] | [(("always" | "never" | "consecutive") | {
|
|
|
7946
7953
|
var?: ("always" | "never" | "consecutive");
|
|
7947
7954
|
let?: ("always" | "never" | "consecutive");
|
|
7948
7955
|
const?: ("always" | "never" | "consecutive");
|
|
7956
|
+
using?: ("always" | "never" | "consecutive");
|
|
7957
|
+
awaitUsing?: ("always" | "never" | "consecutive");
|
|
7949
7958
|
} | {
|
|
7950
7959
|
initialized?: ("always" | "never" | "consecutive");
|
|
7951
7960
|
uninitialized?: ("always" | "never" | "consecutive");
|
|
@@ -9742,7 +9751,6 @@ type PrettierPrettier = [] | [{
|
|
|
9742
9751
|
fileInfoOptions?: {
|
|
9743
9752
|
[k: string]: unknown | undefined;
|
|
9744
9753
|
};
|
|
9745
|
-
[k: string]: unknown | undefined;
|
|
9746
9754
|
}];
|
|
9747
9755
|
type QuoteProps = ([] | [("always" | "as-needed" | "consistent" | "consistent-as-needed")] | [] | [("always" | "as-needed" | "consistent" | "consistent-as-needed")] | [("always" | "as-needed" | "consistent" | "consistent-as-needed"), {
|
|
9748
9756
|
keywords?: boolean;
|
|
@@ -10111,6 +10119,11 @@ type UnocssEnforceClassCompile = [] | [{
|
|
|
10111
10119
|
prefix?: string;
|
|
10112
10120
|
enableFix?: boolean;
|
|
10113
10121
|
}];
|
|
10122
|
+
type UnocssOrder = [] | [{
|
|
10123
|
+
unoFunctions?: string[];
|
|
10124
|
+
unoVariables?: string[];
|
|
10125
|
+
[k: string]: unknown | undefined;
|
|
10126
|
+
}];
|
|
10114
10127
|
type UnusedImportsNoUnusedImports = [] | [(("all" | "local") | {
|
|
10115
10128
|
args?: ("all" | "after-used" | "none");
|
|
10116
10129
|
argsIgnorePattern?: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@sxzz/eslint-config",
|
|
3
|
-
"version": "7.1.
|
|
3
|
+
"version": "7.1.3",
|
|
4
4
|
"description": "ESLint config for @sxzz.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"type": "git",
|
|
13
13
|
"url": "git+https://github.com/sxzz/eslint-config.git"
|
|
14
14
|
},
|
|
15
|
-
"author": "
|
|
15
|
+
"author": "Kevin Deng <sxzz@sxzz.moe>",
|
|
16
16
|
"funding": "https://github.com/sponsors/sxzz",
|
|
17
17
|
"files": [
|
|
18
18
|
"dist"
|
|
@@ -38,22 +38,22 @@
|
|
|
38
38
|
},
|
|
39
39
|
"dependencies": {
|
|
40
40
|
"@eslint-community/eslint-plugin-eslint-comments": "^4.5.0",
|
|
41
|
-
"@eslint/js": "^9.
|
|
41
|
+
"@eslint/js": "^9.33.0",
|
|
42
42
|
"@eslint/markdown": "^7.1.0",
|
|
43
43
|
"eslint-config-flat-gitignore": "^2.1.0",
|
|
44
44
|
"eslint-config-prettier": "^10.1.8",
|
|
45
45
|
"eslint-flat-config-utils": "^2.1.1",
|
|
46
46
|
"eslint-plugin-antfu": "^3.1.1",
|
|
47
47
|
"eslint-plugin-command": "^3.3.1",
|
|
48
|
-
"eslint-plugin-de-morgan": "^1.3.
|
|
48
|
+
"eslint-plugin-de-morgan": "^1.3.1",
|
|
49
49
|
"eslint-plugin-import-x": "^4.16.1",
|
|
50
|
-
"eslint-plugin-jsdoc": "^
|
|
50
|
+
"eslint-plugin-jsdoc": "^54.1.0",
|
|
51
51
|
"eslint-plugin-jsonc": "^2.20.1",
|
|
52
52
|
"eslint-plugin-n": "^17.21.3",
|
|
53
53
|
"eslint-plugin-perfectionist": "^4.15.0",
|
|
54
|
-
"eslint-plugin-pnpm": "^1.1.
|
|
55
|
-
"eslint-plugin-prettier": "^5.5.
|
|
56
|
-
"eslint-plugin-regexp": "^2.
|
|
54
|
+
"eslint-plugin-pnpm": "^1.1.1",
|
|
55
|
+
"eslint-plugin-prettier": "^5.5.4",
|
|
56
|
+
"eslint-plugin-regexp": "^2.10.0",
|
|
57
57
|
"eslint-plugin-sxzz": "^0.4.0",
|
|
58
58
|
"eslint-plugin-unicorn": "^60.0.0",
|
|
59
59
|
"eslint-plugin-unused-imports": "^4.1.4",
|
|
@@ -63,21 +63,21 @@
|
|
|
63
63
|
"jsonc-eslint-parser": "^2.4.0",
|
|
64
64
|
"local-pkg": "^1.1.1",
|
|
65
65
|
"prettier": "^3.6.2",
|
|
66
|
-
"typescript-eslint": "^8.
|
|
66
|
+
"typescript-eslint": "^8.39.1",
|
|
67
67
|
"vue-eslint-parser": "^10.2.0",
|
|
68
68
|
"yaml-eslint-parser": "^1.3.0"
|
|
69
69
|
},
|
|
70
70
|
"devDependencies": {
|
|
71
|
-
"@eslint/config-inspector": "^1.
|
|
71
|
+
"@eslint/config-inspector": "^1.2.0",
|
|
72
72
|
"@sxzz/prettier-config": "^2.2.3",
|
|
73
|
-
"@types/node": "^24.
|
|
74
|
-
"@unocss/eslint-plugin": "^66.
|
|
73
|
+
"@types/node": "^24.3.0",
|
|
74
|
+
"@unocss/eslint-plugin": "^66.4.2",
|
|
75
75
|
"ansis": "^4.1.0",
|
|
76
|
-
"bumpp": "^10.2.
|
|
77
|
-
"eslint": "^9.
|
|
76
|
+
"bumpp": "^10.2.3",
|
|
77
|
+
"eslint": "^9.33.0",
|
|
78
78
|
"eslint-typegen": "^2.3.0",
|
|
79
|
-
"tsdown": "^0.
|
|
80
|
-
"tsx": "^4.20.
|
|
79
|
+
"tsdown": "^0.14.1",
|
|
80
|
+
"tsx": "^4.20.4",
|
|
81
81
|
"typescript": "^5.9.2"
|
|
82
82
|
},
|
|
83
83
|
"engines": {
|
|
@@ -89,7 +89,8 @@
|
|
|
89
89
|
"build": "pnpm run build:typegen && tsdown",
|
|
90
90
|
"build:typegen": "tsx scripts/typegen.ts",
|
|
91
91
|
"build:inspector": "eslint-config-inspector build --config eslint-inspector.config.ts",
|
|
92
|
-
"
|
|
92
|
+
"test": "echo Skip",
|
|
93
|
+
"lint": "eslint --max-warnings=0",
|
|
93
94
|
"lint:fix": "pnpm run lint --fix",
|
|
94
95
|
"release": "bumpp && pnpm publish",
|
|
95
96
|
"typecheck": "tsc --noEmit"
|