@effect/tsgo 0.53.4 → 0.54.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/README.md +3 -2
- package/dist/effect-tsgo.cjs +24 -4
- package/oxlint-presets/correctness.json +1 -0
- package/oxlint-presets/index.js +3 -0
- package/oxlint-presets/recommended.json +1 -0
- package/oxlint-presets/strict.json +1 -0
- package/oxlint-schema.json +3 -0
- package/package.json +8 -8
- package/schema.json +5 -0
package/README.md
CHANGED
|
@@ -38,11 +38,11 @@ When running in dedicated diagnostics mode, the Effect diagnostics can be emitte
|
|
|
38
38
|
<!-- supported-components:start -->
|
|
39
39
|
## Supported Package Versions
|
|
40
40
|
|
|
41
|
-
The following target package versions are supported by `@effect/tsgo@0.
|
|
41
|
+
The following target package versions are supported by `@effect/tsgo@0.54.0`:
|
|
42
42
|
|
|
43
43
|
| Component | Supported versions |
|
|
44
44
|
|---|---|
|
|
45
|
-
| TypeScript | `7.0.2`, `7.1.0-dev.
|
|
45
|
+
| TypeScript | `7.0.2`, `7.1.0-dev.20261018.1` |
|
|
46
46
|
| Oxlint | `1.86.0`, `1.87.0`, `1.88.0` |
|
|
47
47
|
| oxlint-tsgolint | `7.0.2003`, `7.0.2004` |
|
|
48
48
|
<!-- supported-components:end -->
|
|
@@ -79,6 +79,7 @@ Some diagnostics are off by default or have a default severity of suggestion, bu
|
|
|
79
79
|
<tr><td><a href="https://github.com/Effect-TS/tsgo/blob/main/docs/rules/overridden-schema-constructor.md"><code>overriddenSchemaConstructor</code></a></td><td>Prevents overriding constructors in Schema classes which breaks decoding behavior</td></tr>
|
|
80
80
|
<tr><td><a href="https://github.com/Effect-TS/tsgo/blob/main/docs/rules/promise-in-effect-success.md"><code>promiseInEffectSuccess</code></a></td><td>Detects Promise types in Effect success channels where they are not awaited</td></tr>
|
|
81
81
|
<tr><td><a href="https://github.com/Effect-TS/tsgo/blob/main/docs/rules/schema-class-missing-brand.md"><code>schemaClassMissingBrand</code></a></td><td>Warns when Schema classes, errors, or Opaque classes omit the brand type argument</td></tr>
|
|
82
|
+
<tr><td><a href="https://github.com/Effect-TS/tsgo/blob/main/docs/rules/schema-class-object-literal.md"><code>schemaClassObjectLiteral</code></a></td><td>Warns when object literals are checked as Schema class instances without the class prototype</td></tr>
|
|
82
83
|
<tr><td><a href="https://github.com/Effect-TS/tsgo/blob/main/docs/rules/schema-literal-non-finite.md"><code>schemaLiteralNonFinite</code></a></td><td>Reports statically known non-finite numbers passed to Schema literal constructors</td></tr>
|
|
83
84
|
<tr><td><a href="https://github.com/Effect-TS/tsgo/blob/main/docs/rules/schema-opaque-instance-member.md"><code>schemaOpaqueInstanceMember</code></a></td><td>Disallows instance members in classes extending Schema.Opaque</td></tr>
|
|
84
85
|
<tr><td><a href="https://github.com/Effect-TS/tsgo/blob/main/docs/rules/unsafe-effect-type-assertion.md"><code>unsafeEffectTypeAssertion</code></a></td><td>Detects unsafe type assertions that narrow Effect, Stream, or Layer error or requirements channels</td></tr>
|
package/dist/effect-tsgo.cjs
CHANGED
|
@@ -52737,7 +52737,7 @@ const runWith = (command, config) => {
|
|
|
52737
52737
|
//#endregion
|
|
52738
52738
|
//#region package.json
|
|
52739
52739
|
var name = "@effect/tsgo";
|
|
52740
|
-
var version = "0.
|
|
52740
|
+
var version = "0.54.0";
|
|
52741
52741
|
|
|
52742
52742
|
//#endregion
|
|
52743
52743
|
//#region src/metadata.json
|
|
@@ -52843,6 +52843,7 @@ var presets$1 = [
|
|
|
52843
52843
|
"runEffectInsideEffect": "suggestion",
|
|
52844
52844
|
"runOfExitToRunExit": "suggestion",
|
|
52845
52845
|
"schemaClassMissingBrand": "suggestion",
|
|
52846
|
+
"schemaClassObjectLiteral": "warning",
|
|
52846
52847
|
"schemaLiteralNonFinite": "error",
|
|
52847
52848
|
"schemaNumber": "suggestion",
|
|
52848
52849
|
"schemaOpaqueInstanceMember": "error",
|
|
@@ -52935,6 +52936,7 @@ var presets$1 = [
|
|
|
52935
52936
|
"runEffectInsideEffect": "error",
|
|
52936
52937
|
"runOfExitToRunExit": "error",
|
|
52937
52938
|
"schemaClassMissingBrand": "error",
|
|
52939
|
+
"schemaClassObjectLiteral": "error",
|
|
52938
52940
|
"schemaLiteralNonFinite": "error",
|
|
52939
52941
|
"schemaNumber": "error",
|
|
52940
52942
|
"schemaOpaqueInstanceMember": "error",
|
|
@@ -52978,6 +52980,7 @@ var presets$1 = [
|
|
|
52978
52980
|
"overriddenSchemaConstructor": "warning",
|
|
52979
52981
|
"promiseInEffectSuccess": "warning",
|
|
52980
52982
|
"schemaClassMissingBrand": "warning",
|
|
52983
|
+
"schemaClassObjectLiteral": "warning",
|
|
52981
52984
|
"schemaLiteralNonFinite": "warning",
|
|
52982
52985
|
"schemaOpaqueInstanceMember": "warning",
|
|
52983
52986
|
"unsafeEffectTypeAssertion": "warning",
|
|
@@ -53480,6 +53483,23 @@ var rules = [
|
|
|
53480
53483
|
}]
|
|
53481
53484
|
}
|
|
53482
53485
|
},
|
|
53486
|
+
{
|
|
53487
|
+
"name": "schemaClassObjectLiteral",
|
|
53488
|
+
"group": "correctness",
|
|
53489
|
+
"description": "Warns when object literals are checked as Schema class instances without the class prototype",
|
|
53490
|
+
"defaultSeverity": "warning",
|
|
53491
|
+
"fixable": false,
|
|
53492
|
+
"supportedEffect": ["v3", "v4"],
|
|
53493
|
+
"codes": [377149],
|
|
53494
|
+
"preview": {
|
|
53495
|
+
"sourceText": "import { Schema } from \"effect\"\n\nexport class User extends Schema.Class<User, { readonly brand: unique symbol }>(\"User\")({ name: Schema.String }) {}\nexport const user = User.make({ name: \"a\" })\nexport const copy: User = { ...user }\nexport const renamed = User.make({ ...user, name: \"b\" })\n",
|
|
53496
|
+
"diagnostics": [{
|
|
53497
|
+
"start": 220,
|
|
53498
|
+
"end": 231,
|
|
53499
|
+
"text": "This object literal is checked as an instance of Schema class 'User' but has no class prototype. instanceof checks, methods, and Schema encoding can fail. Use 'User.make(...)' or 'new User(...)' instead. effect(schemaClassObjectLiteral)"
|
|
53500
|
+
}]
|
|
53501
|
+
}
|
|
53502
|
+
},
|
|
53483
53503
|
{
|
|
53484
53504
|
"name": "schemaLiteralNonFinite",
|
|
53485
53505
|
"group": "correctness",
|
|
@@ -55351,7 +55371,7 @@ var metadata_default = {
|
|
|
55351
55371
|
var tags = {
|
|
55352
55372
|
"typescript": {
|
|
55353
55373
|
"latest": "7.0.2",
|
|
55354
|
-
"next": "7.1.0-dev.
|
|
55374
|
+
"next": "7.1.0-dev.20261018.1"
|
|
55355
55375
|
},
|
|
55356
55376
|
"oxlint": { "latest": "1.88.0" },
|
|
55357
55377
|
"oxlint-tsgolint": { "latest": "7.0.2004" }
|
|
@@ -55362,8 +55382,8 @@ var components = {
|
|
|
55362
55382
|
"gitHead": "2bd066d87f5bafd315be9f40889d0a60b9e58e0b",
|
|
55363
55383
|
"provider": "typescript-go"
|
|
55364
55384
|
},
|
|
55365
|
-
"7.1.0-dev.
|
|
55366
|
-
"gitHead": "
|
|
55385
|
+
"7.1.0-dev.20261018.1": {
|
|
55386
|
+
"gitHead": "5237fd46890956e4bb8177a1a05dcd69e4166560",
|
|
55367
55387
|
"provider": "typescript"
|
|
55368
55388
|
}
|
|
55369
55389
|
},
|
|
@@ -27,6 +27,7 @@
|
|
|
27
27
|
"effecttsgo/overridden-schema-constructor": "warn",
|
|
28
28
|
"effecttsgo/promise-in-effect-success": "warn",
|
|
29
29
|
"effecttsgo/schema-class-missing-brand": "warn",
|
|
30
|
+
"effecttsgo/schema-class-object-literal": "warn",
|
|
30
31
|
"effecttsgo/schema-literal-non-finite": "warn",
|
|
31
32
|
"effecttsgo/schema-opaque-instance-member": "warn",
|
|
32
33
|
"effecttsgo/unsafe-effect-type-assertion": "warn",
|
package/oxlint-presets/index.js
CHANGED
|
@@ -60,6 +60,7 @@ export const correctness = {
|
|
|
60
60
|
"effecttsgo/overridden-schema-constructor": "warn",
|
|
61
61
|
"effecttsgo/promise-in-effect-success": "warn",
|
|
62
62
|
"effecttsgo/schema-class-missing-brand": "warn",
|
|
63
|
+
"effecttsgo/schema-class-object-literal": "warn",
|
|
63
64
|
"effecttsgo/schema-literal-non-finite": "warn",
|
|
64
65
|
"effecttsgo/schema-opaque-instance-member": "warn",
|
|
65
66
|
"effecttsgo/unsafe-effect-type-assertion": "warn",
|
|
@@ -192,6 +193,7 @@ export const recommended = {
|
|
|
192
193
|
"effecttsgo/run-effect-inside-effect": "warn",
|
|
193
194
|
"effecttsgo/run-of-exit-to-run-exit": "warn",
|
|
194
195
|
"effecttsgo/schema-class-missing-brand": "warn",
|
|
196
|
+
"effecttsgo/schema-class-object-literal": "warn",
|
|
195
197
|
"effecttsgo/schema-literal-non-finite": "error",
|
|
196
198
|
"effecttsgo/schema-number": "warn",
|
|
197
199
|
"effecttsgo/schema-opaque-instance-member": "error",
|
|
@@ -289,6 +291,7 @@ export const strict = {
|
|
|
289
291
|
"effecttsgo/run-effect-inside-effect": "error",
|
|
290
292
|
"effecttsgo/run-of-exit-to-run-exit": "error",
|
|
291
293
|
"effecttsgo/schema-class-missing-brand": "error",
|
|
294
|
+
"effecttsgo/schema-class-object-literal": "error",
|
|
292
295
|
"effecttsgo/schema-literal-non-finite": "error",
|
|
293
296
|
"effecttsgo/schema-number": "error",
|
|
294
297
|
"effecttsgo/schema-opaque-instance-member": "error",
|
|
@@ -76,6 +76,7 @@
|
|
|
76
76
|
"effecttsgo/run-effect-inside-effect": "warn",
|
|
77
77
|
"effecttsgo/run-of-exit-to-run-exit": "warn",
|
|
78
78
|
"effecttsgo/schema-class-missing-brand": "warn",
|
|
79
|
+
"effecttsgo/schema-class-object-literal": "warn",
|
|
79
80
|
"effecttsgo/schema-literal-non-finite": "error",
|
|
80
81
|
"effecttsgo/schema-number": "warn",
|
|
81
82
|
"effecttsgo/schema-opaque-instance-member": "error",
|
|
@@ -76,6 +76,7 @@
|
|
|
76
76
|
"effecttsgo/run-effect-inside-effect": "error",
|
|
77
77
|
"effecttsgo/run-of-exit-to-run-exit": "error",
|
|
78
78
|
"effecttsgo/schema-class-missing-brand": "error",
|
|
79
|
+
"effecttsgo/schema-class-object-literal": "error",
|
|
79
80
|
"effecttsgo/schema-literal-non-finite": "error",
|
|
80
81
|
"effecttsgo/schema-number": "error",
|
|
81
82
|
"effecttsgo/schema-opaque-instance-member": "error",
|
package/oxlint-schema.json
CHANGED
|
@@ -2548,6 +2548,9 @@
|
|
|
2548
2548
|
"effecttsgo/schema-class-missing-brand": {
|
|
2549
2549
|
"$ref": "#/definitions/RuleNoConfig"
|
|
2550
2550
|
},
|
|
2551
|
+
"effecttsgo/schema-class-object-literal": {
|
|
2552
|
+
"$ref": "#/definitions/RuleNoConfig"
|
|
2553
|
+
},
|
|
2551
2554
|
"effecttsgo/schema-literal-non-finite": {
|
|
2552
2555
|
"$ref": "#/definitions/RuleNoConfig"
|
|
2553
2556
|
},
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@effect/tsgo",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.54.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Effect Language Service for TypeScript-Go — Effect-specific diagnostics and hover features.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -41,13 +41,13 @@
|
|
|
41
41
|
"schema.json"
|
|
42
42
|
],
|
|
43
43
|
"optionalDependencies": {
|
|
44
|
-
"@effect/tsgo-win32-x64": "0.
|
|
45
|
-
"@effect/tsgo-
|
|
46
|
-
"@effect/tsgo-linux-
|
|
47
|
-
"@effect/tsgo-
|
|
48
|
-
"@effect/tsgo-linux-arm": "0.
|
|
49
|
-
"@effect/tsgo-darwin-x64": "0.
|
|
50
|
-
"@effect/tsgo-darwin-arm64": "0.
|
|
44
|
+
"@effect/tsgo-win32-x64": "0.54.0",
|
|
45
|
+
"@effect/tsgo-linux-x64": "0.54.0",
|
|
46
|
+
"@effect/tsgo-linux-arm64": "0.54.0",
|
|
47
|
+
"@effect/tsgo-win32-arm64": "0.54.0",
|
|
48
|
+
"@effect/tsgo-linux-arm": "0.54.0",
|
|
49
|
+
"@effect/tsgo-darwin-x64": "0.54.0",
|
|
50
|
+
"@effect/tsgo-darwin-arm64": "0.54.0"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
53
|
"@effect/platform-node": "^4.0.2",
|
package/schema.json
CHANGED
|
@@ -2823,6 +2823,11 @@
|
|
|
2823
2823
|
"default": "suggestion",
|
|
2824
2824
|
"description": "Warns when Schema classes, errors, or Opaque classes omit the brand type argument"
|
|
2825
2825
|
},
|
|
2826
|
+
"schemaClassObjectLiteral": {
|
|
2827
|
+
"$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
|
|
2828
|
+
"default": "warning",
|
|
2829
|
+
"description": "Warns when object literals are checked as Schema class instances without the class prototype"
|
|
2830
|
+
},
|
|
2826
2831
|
"schemaLiteralNonFinite": {
|
|
2827
2832
|
"$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
|
|
2828
2833
|
"default": "error",
|