@foldkit/oxlint-plugin 0.10.0 → 0.11.0-canary.0053b7691fcd
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/all.json +26 -2
- package/dist/guards.d.ts +13 -9
- package/dist/guards.d.ts.map +1 -1
- package/dist/index.d.ts +6 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +947 -168
- package/dist/message.d.ts.map +1 -1
- package/dist/rules/mount-factory-must-use-element.d.ts +1 -1
- package/dist/rules/mount-factory-must-use-element.d.ts.map +1 -1
- package/dist/rules/no-empty-commands-array.d.ts.map +1 -1
- package/dist/rules/no-empty-to-parent-out-message.d.ts.map +1 -1
- package/dist/rules/no-impure-call-at-decision-time.d.ts +7 -0
- package/dist/rules/no-impure-call-at-decision-time.d.ts.map +1 -0
- package/dist/rules/no-nonportable-server-globals.d.ts.map +1 -1
- package/dist/rules/prefer-effect-module-names.d.ts +3 -0
- package/dist/rules/prefer-effect-module-names.d.ts.map +1 -0
- package/package.json +7 -6
- package/recommended.json +26 -2
package/all.json
CHANGED
|
@@ -24,12 +24,14 @@
|
|
|
24
24
|
"foldkit/no-empty-object-tagged-call": "error",
|
|
25
25
|
"foldkit/no-hand-rolled-command-struct": "error",
|
|
26
26
|
"foldkit/no-hardcoded-route-strings": "error",
|
|
27
|
+
"foldkit/no-impure-call-at-decision-time": "error",
|
|
27
28
|
"foldkit/no-module-level-mutable-state": "error",
|
|
28
29
|
"foldkit/no-nonportable-server-globals": "off",
|
|
29
30
|
"foldkit/no-noop-message": "error",
|
|
30
31
|
"foldkit/no-raw-dom-event-attributes": "error",
|
|
31
32
|
"foldkit/no-spread-in-evo": "error",
|
|
32
33
|
"foldkit/prefer-callable-message-constructor": "error",
|
|
34
|
+
"foldkit/prefer-effect-module-names": "error",
|
|
33
35
|
"foldkit/require-rel-for-external-link": "error",
|
|
34
36
|
"foldkit/selection-submodel-factory-at-module-scope": "error",
|
|
35
37
|
"foldkit/wrap-child-output-in-got-message": "error"
|
|
@@ -41,7 +43,8 @@
|
|
|
41
43
|
"**/entry.server.tsx",
|
|
42
44
|
"**/server/**/*.ts",
|
|
43
45
|
"**/server/**/*.tsx",
|
|
44
|
-
"**/prerender.ts"
|
|
46
|
+
"**/prerender.ts",
|
|
47
|
+
"**/prerender.tsx"
|
|
45
48
|
],
|
|
46
49
|
"excludeFiles": [
|
|
47
50
|
"**/*.test.ts",
|
|
@@ -50,7 +53,27 @@
|
|
|
50
53
|
"**/*.spec.tsx"
|
|
51
54
|
],
|
|
52
55
|
"rules": {
|
|
53
|
-
"foldkit/no-nonportable-server-globals": "error"
|
|
56
|
+
"foldkit/no-nonportable-server-globals": "error",
|
|
57
|
+
"foldkit/no-impure-call-at-decision-time": "off"
|
|
58
|
+
}
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
"files": [
|
|
62
|
+
"**/entry.ts",
|
|
63
|
+
"**/entry.tsx",
|
|
64
|
+
"**/entry.client.ts",
|
|
65
|
+
"**/entry.client.tsx",
|
|
66
|
+
"**/entry.server.ts",
|
|
67
|
+
"**/entry.server.tsx"
|
|
68
|
+
],
|
|
69
|
+
"excludeFiles": [
|
|
70
|
+
"**/*.test.ts",
|
|
71
|
+
"**/*.test.tsx",
|
|
72
|
+
"**/*.spec.ts",
|
|
73
|
+
"**/*.spec.tsx"
|
|
74
|
+
],
|
|
75
|
+
"rules": {
|
|
76
|
+
"foldkit/no-impure-call-at-decision-time": "off"
|
|
54
77
|
}
|
|
55
78
|
},
|
|
56
79
|
{
|
|
@@ -79,6 +102,7 @@
|
|
|
79
102
|
"foldkit/no-empty-object-tagged-call": "off",
|
|
80
103
|
"foldkit/no-hand-rolled-command-struct": "off",
|
|
81
104
|
"foldkit/no-hardcoded-route-strings": "off",
|
|
105
|
+
"foldkit/no-impure-call-at-decision-time": "off",
|
|
82
106
|
"foldkit/no-module-level-mutable-state": "off",
|
|
83
107
|
"foldkit/no-nonportable-server-globals": "off",
|
|
84
108
|
"foldkit/no-noop-message": "off",
|
package/dist/guards.d.ts
CHANGED
|
@@ -1,27 +1,31 @@
|
|
|
1
1
|
import { Option } from 'effect';
|
|
2
|
-
import { type ESTree } from 'effect-oxlint';
|
|
2
|
+
import { type ESTree, type OxlintScope, type Reference } from 'effect-oxlint';
|
|
3
3
|
export declare const isIdentifier: (node: unknown, name?: string) => node is Readonly<{
|
|
4
|
-
type:
|
|
4
|
+
type: 'Identifier';
|
|
5
5
|
name: string;
|
|
6
6
|
}>;
|
|
7
|
+
export declare const isIdentifierReference: (node: unknown) => node is ESTree.IdentifierReference;
|
|
7
8
|
export declare const isStringLiteral: (node: unknown) => node is ESTree.StringLiteral;
|
|
8
9
|
export declare const isTemplateLiteral: (node: unknown) => node is ESTree.TemplateLiteral;
|
|
9
10
|
export declare const isCallExpression: (node: unknown) => node is ESTree.CallExpression;
|
|
10
|
-
export declare const isMemberExpression: (node: unknown) => node is
|
|
11
|
-
type: "MemberExpression";
|
|
12
|
-
object: unknown;
|
|
13
|
-
property: unknown;
|
|
14
|
-
computed?: boolean;
|
|
15
|
-
}>;
|
|
11
|
+
export declare const isMemberExpression: (node: unknown) => node is ESTree.MemberExpression;
|
|
16
12
|
export declare const isObjectExpression: (node: unknown) => node is ESTree.ObjectExpression;
|
|
13
|
+
export declare const isObjectProperty: (node: unknown) => node is ESTree.ObjectProperty;
|
|
17
14
|
export declare const isArrayExpression: (node: unknown) => node is Readonly<{
|
|
18
|
-
type:
|
|
15
|
+
type: 'ArrayExpression';
|
|
19
16
|
elements: ReadonlyArray<unknown>;
|
|
20
17
|
}>;
|
|
21
18
|
export declare const isSpreadElement: (node: unknown) => boolean;
|
|
22
19
|
export declare const helperCalleeName: (callee: unknown) => Option.Option<string>;
|
|
23
20
|
export declare const calleeMatchesHelperName: (callee: unknown, helperName: string) => boolean;
|
|
24
21
|
export declare const staticStringValue: (node: unknown) => Option.Option<string>;
|
|
22
|
+
export declare const staticMemberName: (node: ESTree.MemberExpression) => Option.Option<string>;
|
|
23
|
+
export declare const staticPropertyName: (property: Readonly<{
|
|
24
|
+
computed?: boolean;
|
|
25
|
+
key: ESTree.PropertyKey;
|
|
26
|
+
}>) => Option.Option<string>;
|
|
27
|
+
export declare const indexReferences: (scopes: ReadonlyArray<OxlintScope>) => WeakMap<ESTree.Node, Reference>;
|
|
28
|
+
export declare const isUnshadowedReference: (references: WeakMap<ESTree.Node, Reference> | undefined, node: ESTree.Node) => boolean;
|
|
25
29
|
export declare const isVariableDeclarator: (node: unknown) => node is ESTree.VariableDeclarator;
|
|
26
30
|
export declare const isVariableDeclaration: (node: unknown) => node is ESTree.VariableDeclaration;
|
|
27
31
|
export declare const isProgram: (node: unknown) => node is ESTree.Program;
|
package/dist/guards.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"guards.d.ts","sourceRoot":"","sources":["../src/guards.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,MAAM,EAAE,MAAM,QAAQ,CAAA;AACtC,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,eAAe,CAAA;
|
|
1
|
+
{"version":3,"file":"guards.d.ts","sourceRoot":"","sources":["../src/guards.ts"],"names":[],"mappings":"AAAA,OAAO,EAAS,MAAM,EAAE,MAAM,QAAQ,CAAA;AACtC,OAAO,EAAE,KAAK,MAAM,EAAE,KAAK,WAAW,EAAE,KAAK,SAAS,EAAE,MAAM,eAAe,CAAA;AAE7E,eAAO,MAAM,YAAY,SACjB,OAAO,SACN,MAAM,KACZ,IAAI,IAAI,QAAQ,CAAC;IAAE,IAAI,EAAE,YAAY,CAAC;IAAC,IAAI,EAAE,MAAM,CAAA;CAAE,CAOZ,CAAA;AAE5C,eAAO,MAAM,qBAAqB,SAC1B,OAAO,KACZ,IAAI,IAAI,MAAM,CAAC,mBAAyC,CAAA;AAE3D,eAAO,MAAM,eAAe,SAAU,OAAO,KAAG,IAAI,IAAI,MAAM,CAAC,aAM/B,CAAA;AAEhC,eAAO,MAAM,iBA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,IAAI,EAAE,SAAS,CAShC,CAAA;AAED,eAAO,MAAM,qBAAqB,eACpB,OAAO,CAAC,MAAM,CAAC,IAAI,EAAE,SAAS,CAAC,GAAG,SAAS,QACjD,MAAM,CAAC,IAAI,KAChB,OAUF,CAAA;AAED,eAAO,MAAM,oBAAoB,SACzB,OAAO,KACZ,IAAI,IAAI,MAAM,CAAC,kBAIkB,CAAA;AAEpC,eAAO,MAAM,qBAAqB,SAC1B,OAAO,KACZ,IAAI,IAAI,MAAM,CAAC,mBAImB,CAAA;AAErC,eAAO,MAAM,SAAS,SAAU,OAAO,KAAG,IAAI,IAAI,MAAM,CAAC,OAIhC,CAAA;AAEzB,eAAO,MAAM,mBAAmB,SACxB,MAAM,CAAC,cAAc,KAC1B,MAAM,CAAC,aAAa,GAAG,SAGzB,CAAA"}
|
package/dist/index.d.ts
CHANGED
|
@@ -8,10 +8,6 @@ type OverriddenConfig = Plugin.OxlintConfig & {
|
|
|
8
8
|
overrides: Array<Override>;
|
|
9
9
|
};
|
|
10
10
|
declare const _default: {
|
|
11
|
-
configs: {
|
|
12
|
-
recommended: OverriddenConfig;
|
|
13
|
-
all: OverriddenConfig;
|
|
14
|
-
};
|
|
15
11
|
meta: {
|
|
16
12
|
readonly name: string;
|
|
17
13
|
};
|
|
@@ -34,16 +30,22 @@ declare const _default: {
|
|
|
34
30
|
readonly 'no-empty-object-tagged-call': import("effect-oxlint").CreateRule;
|
|
35
31
|
readonly 'no-hand-rolled-command-struct': import("effect-oxlint").CreateRule;
|
|
36
32
|
readonly 'no-hardcoded-route-strings': import("effect-oxlint").CreateRule;
|
|
33
|
+
readonly 'no-impure-call-at-decision-time': import("effect-oxlint").CreateRule;
|
|
37
34
|
readonly 'no-module-level-mutable-state': import("effect-oxlint").CreateRule;
|
|
38
35
|
readonly 'no-nonportable-server-globals': import("effect-oxlint").CreateRule;
|
|
39
36
|
readonly 'no-noop-message': import("effect-oxlint").CreateRule;
|
|
40
37
|
readonly 'no-raw-dom-event-attributes': import("effect-oxlint").CreateRule;
|
|
41
38
|
readonly 'no-spread-in-evo': import("effect-oxlint").CreateRule;
|
|
42
39
|
readonly 'prefer-callable-message-constructor': import("effect-oxlint").CreateRule;
|
|
40
|
+
readonly 'prefer-effect-module-names': import("effect-oxlint").CreateRule;
|
|
43
41
|
readonly 'require-rel-for-external-link': import("effect-oxlint").CreateRule;
|
|
44
42
|
readonly 'selection-submodel-factory-at-module-scope': import("effect-oxlint").CreateRule;
|
|
45
43
|
readonly 'wrap-child-output-in-got-message': import("effect-oxlint").CreateRule;
|
|
46
44
|
};
|
|
45
|
+
configs: {
|
|
46
|
+
recommended: OverriddenConfig;
|
|
47
|
+
all: OverriddenConfig;
|
|
48
|
+
};
|
|
47
49
|
};
|
|
48
50
|
export default _default;
|
|
49
51
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAA;AAqEtC,KAAK,QAAQ,GAAG,QAAQ,CAAC;IACvB,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;IACpB,YAAY,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,CAAA;IAC5B,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,YAAY,CAAC,CAAA;CAC3C,CAAC,CAAA;AAEF,KAAK,gBAAgB,GAAG,MAAM,CAAC,YAAY,GAAG;IAC5C,SAAS,EAAE,KAAK,CAAC,QAAQ,CAAC,CAAA;CAC3B,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;QAyEG,WAAW;QACX,GAAG"}
|