@effect/tsgo 0.63.0 → 0.67.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/schema.json CHANGED
@@ -1564,6 +1564,28 @@
1564
1564
  },
1565
1565
  "type": "array"
1566
1566
  },
1567
+ "brandedSchemaClasses": {
1568
+ "default": [
1569
+ "Class",
1570
+ "TaggedClass",
1571
+ "Error",
1572
+ "TaggedError",
1573
+ "Opaque"
1574
+ ],
1575
+ "description": "Schema class kinds that get a nominal brand, used by schemaClassMissingBrand and the Schema class completions.",
1576
+ "items": {
1577
+ "enum": [
1578
+ "Class",
1579
+ "TaggedClass",
1580
+ "Error",
1581
+ "TaggedError",
1582
+ "Opaque"
1583
+ ],
1584
+ "type": "string"
1585
+ },
1586
+ "type": "array",
1587
+ "uniqueItems": true
1588
+ },
1567
1589
  "completions": {
1568
1590
  "default": true,
1569
1591
  "description": "Controls Effect completions.",
@@ -2432,12 +2454,12 @@
2432
2454
  "cryptoRandomUUID": {
2433
2455
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2434
2456
  "default": "off",
2435
- "description": "Warns when using crypto.randomUUID() outside Effect generators instead of the Effect Crypto module"
2457
+ "description": "Warns when using crypto.randomUUID() outside Effect generators instead of SecureRandom from effect/crypto"
2436
2458
  },
2437
2459
  "cryptoRandomUUIDInEffect": {
2438
2460
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2439
2461
  "default": "off",
2440
- "description": "Warns when using crypto.randomUUID() inside Effect generators instead of the Effect Crypto module"
2462
+ "description": "Warns when using crypto.randomUUID() inside Effect generators instead of SecureRandom from effect/crypto"
2441
2463
  },
2442
2464
  "deterministicKeys": {
2443
2465
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
@@ -2499,11 +2521,21 @@
2499
2521
  "default": "suggestion",
2500
2522
  "description": "Suggests Effect.yieldNow for cooperative yielding instead of sleeping for zero duration"
2501
2523
  },
2524
+ "effectSucceedWithUndefined": {
2525
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2526
+ "default": "suggestion",
2527
+ "description": "Suggests using Effect.undefined instead of Effect.succeed(undefined) or Effect.succeed(void 0)"
2528
+ },
2502
2529
  "effectSucceedWithVoid": {
2503
2530
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2504
2531
  "default": "suggestion",
2505
2532
  "description": "Suggests using Effect.void instead of Effect.succeed(undefined) or Effect.succeed(void 0)"
2506
2533
  },
2534
+ "effectTryWithoutCatch": {
2535
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2536
+ "default": "off",
2537
+ "description": "Reports Effect.try and Effect.tryPromise calls without a catch handler, whose failures surface as a generic unknown error"
2538
+ },
2507
2539
  "errorPayloadShadowsName": {
2508
2540
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2509
2541
  "default": "suggestion",
@@ -2604,6 +2636,16 @@
2604
2636
  "default": "off",
2605
2637
  "description": "Warns when using the global fetch function inside Effect generators instead of the Effect HTTP client"
2606
2638
  },
2639
+ "globalJson": {
2640
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2641
+ "default": "off",
2642
+ "description": "Warns when using JSON.parse or JSON.stringify outside Effect generators instead of Effect Schema"
2643
+ },
2644
+ "globalJsonInEffect": {
2645
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2646
+ "default": "off",
2647
+ "description": "Warns when using JSON.parse or JSON.stringify inside Effect generators instead of Effect Schema"
2648
+ },
2607
2649
  "globalRandom": {
2608
2650
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2609
2651
  "default": "off",
@@ -2664,11 +2706,21 @@
2664
2706
  "default": "off",
2665
2707
  "description": "Suggests Effect.mapBoth when Effect.map and Effect.mapError are adjacent steps of a piping flow"
2666
2708
  },
2709
+ "mapSomeCatchNoSuchElement": {
2710
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2711
+ "default": "suggestion",
2712
+ "description": "Suggests Effect.catchNoSuchElement instead of wrapping successes in Option.some and catching NoSuchElementError into Option.none"
2713
+ },
2667
2714
  "mapSomeToAsSome": {
2668
2715
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2669
2716
  "default": "suggestion",
2670
2717
  "description": "Suggests using Effect.asSome instead of Effect.map when the mapper only wraps the success value with Option.some"
2671
2718
  },
2719
+ "matchBooleanToIsSuccess": {
2720
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2721
+ "default": "suggestion",
2722
+ "description": "Suggests Effect.isSuccess or Effect.isFailure when Effect.match or Effect.matchEager folds to complementary boolean literals"
2723
+ },
2672
2724
  "matchEffectToMapBoth": {
2673
2725
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2674
2726
  "default": "suggestion",
@@ -2679,6 +2731,11 @@
2679
2731
  "default": "suggestion",
2680
2732
  "description": "Suggests Effect.match or Effect.matchCause when both Effect.matchEffect handlers only return Effect.succeed"
2681
2733
  },
2734
+ "matchToResultOrOption": {
2735
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2736
+ "default": "suggestion",
2737
+ "description": "Suggests Effect.result, Effect.option or Effect.either when match handlers, or a map step followed by a catch step, only reify the outcome"
2738
+ },
2682
2739
  "missedPipeableOpportunity": {
2683
2740
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2684
2741
  "default": "off",
@@ -2807,7 +2864,7 @@
2807
2864
  "preferSchemaOverJson": {
2808
2865
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2809
2866
  "default": "off",
2810
- "description": "Suggests using Effect Schema for JSON operations instead of JSON.parse/JSON.stringify"
2867
+ "description": "Deprecated: use globalJsonInEffect and globalJson instead. Suggests using Effect Schema for JSON operations instead of JSON.parse/JSON.stringify inside Effect code"
2811
2868
  },
2812
2869
  "preferSchemaTaggedError": {
2813
2870
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
@@ -2854,6 +2911,11 @@
2854
2911
  "default": "suggestion",
2855
2912
  "description": "Suggests providing inline Layer.succeed and Layer.effect services directly"
2856
2913
  },
2914
+ "provideMergeAllToArray": {
2915
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2916
+ "default": "off",
2917
+ "description": "Suggests passing an array of layers to Effect.provide instead of wrapping them in Layer.mergeAll"
2918
+ },
2857
2919
  "raceFirstWithSleepToTimeout": {
2858
2920
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2859
2921
  "default": "suggestion",
@@ -2874,6 +2936,11 @@
2874
2936
  "default": "suggestion",
2875
2937
  "description": "Suggests removing redundant identifier argument when it equals the tag value in Schema.TaggedClass/TaggedError/TaggedRequest"
2876
2938
  },
2939
+ "resultMatchToFromResult": {
2940
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2941
+ "default": "suggestion",
2942
+ "description": "Suggests Effect.fromResult when Result.match or a Result guard conditional only converts Success to Effect.succeed and Failure to Effect.fail"
2943
+ },
2877
2944
  "returnEffectInGen": {
2878
2945
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2879
2946
  "default": "suggestion",
@@ -2954,6 +3021,11 @@
2954
3021
  "default": "off",
2955
3022
  "description": "Warns when using Effect.provide with layers outside of application entry points"
2956
3023
  },
3024
+ "suspendFailToFailSync": {
3025
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
3026
+ "default": "suggestion",
3027
+ "description": "Suggests Effect.failSync/dieSync instead of Effect.suspend wrapping a single Effect.fail/die"
3028
+ },
2957
3029
  "syncToSucceed": {
2958
3030
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2959
3031
  "default": "suggestion",
@@ -2969,6 +3041,11 @@
2969
3041
  "default": "suggestion",
2970
3042
  "description": "Discourages try/catch in Effect generators in favor of Effect error handling"
2971
3043
  },
3044
+ "typeUnionToSchemaUnion": {
3045
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
3046
+ "default": "off",
3047
+ "description": "Suggests composing unions of Schema .Type/.Encoded types with Schema.Union and deriving the type from it"
3048
+ },
2972
3049
  "unknownInEffectCatch": {
2973
3050
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
2974
3051
  "default": "warning",
@@ -3013,6 +3090,11 @@
3013
3090
  "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
3014
3091
  "default": "warning",
3015
3092
  "description": "Warns when using an API marked @stability unstable"
3093
+ },
3094
+ "yieldInCallArgument": {
3095
+ "$ref": "#/definitions/effectLanguageServicePluginSeverityDefinition",
3096
+ "default": "off",
3097
+ "description": "Suggests yielding into a const before a call instead of passing a yield* directly as a call or new argument in Effect generators"
3016
3098
  }
3017
3099
  },
3018
3100
  "type": "object"
@@ -3090,6 +3172,28 @@
3090
3172
  },
3091
3173
  "type": "array"
3092
3174
  },
3175
+ "brandedSchemaClasses": {
3176
+ "default": [
3177
+ "Class",
3178
+ "TaggedClass",
3179
+ "Error",
3180
+ "TaggedError",
3181
+ "Opaque"
3182
+ ],
3183
+ "description": "Schema class kinds that get a nominal brand, used by schemaClassMissingBrand and the Schema class completions.",
3184
+ "items": {
3185
+ "enum": [
3186
+ "Class",
3187
+ "TaggedClass",
3188
+ "Error",
3189
+ "TaggedError",
3190
+ "Opaque"
3191
+ ],
3192
+ "type": "string"
3193
+ },
3194
+ "type": "array",
3195
+ "uniqueItems": true
3196
+ },
3093
3197
  "completions": {
3094
3198
  "default": true,
3095
3199
  "description": "Controls Effect completions.",
@@ -3313,6 +3417,21 @@
3313
3417
  },
3314
3418
  "type": "array"
3315
3419
  },
3420
+ "brandedSchemaClasses": {
3421
+ "description": "Scoped override for the Schema class kinds that get a nominal brand.",
3422
+ "items": {
3423
+ "enum": [
3424
+ "Class",
3425
+ "TaggedClass",
3426
+ "Error",
3427
+ "TaggedError",
3428
+ "Opaque"
3429
+ ],
3430
+ "type": "string"
3431
+ },
3432
+ "type": "array",
3433
+ "uniqueItems": true
3434
+ },
3316
3435
  "diagnosticSeverity": {
3317
3436
  "$ref": "#/definitions/effectLanguageServicePluginDiagnosticSeverityDefinition",
3318
3437
  "description": "Severity overrides applied when this override matches."