@resolid/config 5.3.23 → 5.3.25
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/README.md +1 -1
- package/oxlint/javascript.js +11 -0
- package/oxlint/react.js +12 -23
- package/oxlint/typescript.js +2 -1
- package/package.json +7 -12
package/README.md
CHANGED
package/oxlint/javascript.js
CHANGED
|
@@ -23,6 +23,8 @@ export default defineConfig({
|
|
|
23
23
|
rules: {
|
|
24
24
|
curly: "warn",
|
|
25
25
|
"guard-for-in": "warn",
|
|
26
|
+
"logical-assignment-operators": "error",
|
|
27
|
+
"object-shorthand": "error",
|
|
26
28
|
|
|
27
29
|
"no-case-declarations": "error",
|
|
28
30
|
"no-empty": "error",
|
|
@@ -33,6 +35,7 @@ export default defineConfig({
|
|
|
33
35
|
"no-var": "error",
|
|
34
36
|
"no-array-constructor": "error",
|
|
35
37
|
"no-useless-call": "error",
|
|
38
|
+
"no-useless-assignment": "error",
|
|
36
39
|
"no-await-in-loop": "error",
|
|
37
40
|
"no-template-curly-in-string": "error",
|
|
38
41
|
|
|
@@ -44,6 +47,8 @@ export default defineConfig({
|
|
|
44
47
|
"prefer-object-spread": "warn",
|
|
45
48
|
"prefer-exponentiation-operator": "warn",
|
|
46
49
|
"prefer-numeric-literals": "warn",
|
|
50
|
+
"prefer-named-capture-group": "error",
|
|
51
|
+
"prefer-regex-literals": "error",
|
|
47
52
|
|
|
48
53
|
"import/export": "error",
|
|
49
54
|
"import/named": "error",
|
|
@@ -51,6 +56,12 @@ export default defineConfig({
|
|
|
51
56
|
"import/no-named-as-default-member": "warn",
|
|
52
57
|
"import/no-duplicates": "warn",
|
|
53
58
|
|
|
59
|
+
"unicorn/no-useless-iterator-to-array": "error",
|
|
60
|
+
"unicorn/prefer-import-meta-properties": "error",
|
|
61
|
+
"unicorn/prefer-module": "error",
|
|
62
|
+
"unicorn/prefer-ternary": "error",
|
|
63
|
+
"unicorn/switch-case-break-position": "error",
|
|
64
|
+
|
|
54
65
|
"oxc/no-accumulating-spread": "error",
|
|
55
66
|
"oxc/no-map-spread": "error",
|
|
56
67
|
},
|
package/oxlint/react.js
CHANGED
|
@@ -2,10 +2,6 @@ import { defineConfig } from "oxlint";
|
|
|
2
2
|
|
|
3
3
|
export default defineConfig({
|
|
4
4
|
jsPlugins: [
|
|
5
|
-
{
|
|
6
|
-
name: "react-hooks-js",
|
|
7
|
-
specifier: "eslint-plugin-react-hooks",
|
|
8
|
-
},
|
|
9
5
|
{
|
|
10
6
|
name: "react-you-might-not-need-an-effect-js",
|
|
11
7
|
specifier: "eslint-plugin-react-you-might-not-need-an-effect",
|
|
@@ -27,6 +23,13 @@ export default defineConfig({
|
|
|
27
23
|
"react/jsx-pascal-case": "error",
|
|
28
24
|
"react/jsx-curly-brace-presence": "warn",
|
|
29
25
|
"react/jsx-no-useless-fragment": "warn",
|
|
26
|
+
"react/prefer-function-component": "error",
|
|
27
|
+
"react/no-unstable-nested-components": "error",
|
|
28
|
+
"react/jsx-no-constructed-context-values": "error",
|
|
29
|
+
"react/no-array-index-key": "error",
|
|
30
|
+
"react/no-clone-element": "error",
|
|
31
|
+
"react/hook-use-state": "error",
|
|
32
|
+
"react/jsx-handler-names": "error",
|
|
30
33
|
"react/only-export-components": [
|
|
31
34
|
"warn",
|
|
32
35
|
{
|
|
@@ -53,31 +56,17 @@ export default defineConfig({
|
|
|
53
56
|
"react/rules-of-hooks": "error",
|
|
54
57
|
"react/exhaustive-deps": ["warn", { additionalHooks: "useIsomorphicEffect" }],
|
|
55
58
|
|
|
56
|
-
|
|
57
|
-
"react-hooks-js/config": "error",
|
|
58
|
-
"react-hooks-js/error-boundaries": "error",
|
|
59
|
-
"react-hooks-js/gating": "error",
|
|
60
|
-
"react-hooks-js/globals": "error",
|
|
61
|
-
"react-hooks-js/immutability": "error",
|
|
62
|
-
"react-hooks-js/preserve-manual-memoization": "error",
|
|
63
|
-
"react-hooks-js/purity": "error",
|
|
64
|
-
"react-hooks-js/refs": "error",
|
|
65
|
-
"react-hooks-js/set-state-in-effect": "error",
|
|
66
|
-
"react-hooks-js/set-state-in-render": "error",
|
|
67
|
-
"react-hooks-js/static-components": "error",
|
|
68
|
-
"react-hooks-js/unsupported-syntax": "error",
|
|
69
|
-
"react-hooks-js/use-memo": "error",
|
|
70
|
-
"react-hooks-js/void-use-memo": "error",
|
|
71
|
-
"react-hooks-js/incompatible-library": "error",
|
|
59
|
+
"react/react-compiler": "error",
|
|
72
60
|
|
|
73
61
|
// react-you-might-not-need-an-effect-js Recommended
|
|
62
|
+
"react-you-might-not-need-an-effect-js/no-derived-state": "warn",
|
|
63
|
+
"react-you-might-not-need-an-effect-js/no-chain-state-updates": "warn",
|
|
64
|
+
"react-you-might-not-need-an-effect-js/no-event-handler": "warn",
|
|
74
65
|
"react-you-might-not-need-an-effect-js/no-adjust-state-on-prop-change": "warn",
|
|
75
66
|
"react-you-might-not-need-an-effect-js/no-reset-all-state-on-prop-change": "warn",
|
|
76
|
-
"react-you-might-not-need-an-effect-js/no-event-handler": "warn",
|
|
77
67
|
"react-you-might-not-need-an-effect-js/no-pass-live-state-to-parent": "warn",
|
|
78
68
|
"react-you-might-not-need-an-effect-js/no-pass-data-to-parent": "warn",
|
|
69
|
+
"react-you-might-not-need-an-effect-js/no-external-store-subscription": "warn",
|
|
79
70
|
"react-you-might-not-need-an-effect-js/no-initialize-state": "warn",
|
|
80
|
-
"react-you-might-not-need-an-effect-js/no-chain-state-updates": "warn",
|
|
81
|
-
"react-you-might-not-need-an-effect-js/no-derived-state": "warn",
|
|
82
71
|
},
|
|
83
72
|
});
|
package/oxlint/typescript.js
CHANGED
|
@@ -11,8 +11,9 @@ export default defineConfig({
|
|
|
11
11
|
"typescript/ban-ts-comment": "error",
|
|
12
12
|
"typescript/class-literal-property-style": "warn",
|
|
13
13
|
"typescript/dot-notation": "error",
|
|
14
|
+
"typescript/method-signature-style": "error",
|
|
14
15
|
"typescript/consistent-generic-constructors": ["warn", "type-annotation"],
|
|
15
|
-
"typescript/consistent-indexed-object-style": ["warn"
|
|
16
|
+
"typescript/consistent-indexed-object-style": ["warn"],
|
|
16
17
|
"typescript/consistent-type-assertions": [
|
|
17
18
|
"warn",
|
|
18
19
|
{
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@resolid/config",
|
|
3
|
-
"version": "5.3.
|
|
3
|
+
"version": "5.3.25",
|
|
4
4
|
"description": "Oxlint and Typescript config",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"oxfmt",
|
|
@@ -42,19 +42,17 @@
|
|
|
42
42
|
"@changesets/cli": "^2.31.0",
|
|
43
43
|
"@commitlint/cli": "^21.0.2",
|
|
44
44
|
"@commitlint/config-conventional": "^21.0.2",
|
|
45
|
-
"eslint-plugin-react-
|
|
46
|
-
"eslint-plugin-react-you-might-not-need-an-effect": "^1.0.0",
|
|
45
|
+
"eslint-plugin-react-you-might-not-need-an-effect": "^1.0.1",
|
|
47
46
|
"lefthook": "^2.1.9",
|
|
48
|
-
"oxfmt": "^0.
|
|
49
|
-
"oxlint": "^1.
|
|
47
|
+
"oxfmt": "^0.55.0",
|
|
48
|
+
"oxlint": "^1.70.0",
|
|
50
49
|
"oxlint-tsgolint": "^0.23.0",
|
|
51
50
|
"typescript": "^6.0.3"
|
|
52
51
|
},
|
|
53
52
|
"peerDependencies": {
|
|
54
|
-
"eslint-plugin-react-
|
|
55
|
-
"
|
|
56
|
-
"
|
|
57
|
-
"oxlint": "^1.69.0",
|
|
53
|
+
"eslint-plugin-react-you-might-not-need-an-effect": "^1.0.1",
|
|
54
|
+
"oxfmt": "^0.55.0",
|
|
55
|
+
"oxlint": "^1.70.0",
|
|
58
56
|
"oxlint-tsgolint": "^0.23.0",
|
|
59
57
|
"typescript": "^6.0.3"
|
|
60
58
|
},
|
|
@@ -65,9 +63,6 @@
|
|
|
65
63
|
"oxlint-tsgolint": {
|
|
66
64
|
"optional": true
|
|
67
65
|
},
|
|
68
|
-
"eslint-plugin-react-hooks": {
|
|
69
|
-
"optional": true
|
|
70
|
-
},
|
|
71
66
|
"eslint-plugin-react-you-might-not-need-an-effect": {
|
|
72
67
|
"optional": true
|
|
73
68
|
}
|