functype 1.2.1 → 1.3.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/dist/Logger-75yEf2wp.d.ts +32 -0
- package/dist/cli/exports.d.ts +1 -0
- package/dist/cli/exports.js +1 -1
- package/dist/cli/index.js +5 -5
- package/dist/do/index.d.ts +1 -1
- package/dist/do/index.js +1 -1
- package/dist/either/index.d.ts +1 -1
- package/dist/either/index.js +1 -1
- package/dist/{full-interfaces-BVPNJJWs.js → full-interfaces-0pOr6idp.js} +37 -2
- package/dist/{index-CiC77m4A.d.ts → index-DBYBJg-D.d.ts} +239 -102
- package/dist/index.d.ts +3 -2
- package/dist/index.js +1 -1
- package/dist/list/index.d.ts +1 -1
- package/dist/list/index.js +1 -1
- package/dist/logger/index.d.ts +2 -0
- package/dist/logger/index.js +0 -0
- package/dist/map/index.d.ts +1 -1
- package/dist/map/index.js +1 -1
- package/dist/option/index.d.ts +1 -1
- package/dist/option/index.js +1 -1
- package/dist/set/index.d.ts +1 -1
- package/dist/set/index.js +1 -1
- package/dist/src-P2lgP6cJ.js +17 -0
- package/dist/try/index.d.ts +1 -1
- package/dist/try/index.js +1 -1
- package/package.json +8 -3
- package/dist/src-D3v1n1vv.js +0 -17
|
@@ -315,7 +315,7 @@ interface SerializationResult {
|
|
|
315
315
|
* `"Some"`, `"Left"`, `"Success"`). A value WITHOUT this marker is treated
|
|
316
316
|
* as "not ours" by `Serialization.deserialize`.
|
|
317
317
|
*
|
|
318
|
-
* See `docs/proposals/universal-deserialize-changes.md` Change 0 for the
|
|
318
|
+
* See `docs/archive/proposals/universal-deserialize-changes.md` Change 0 for the
|
|
319
319
|
* full rationale.
|
|
320
320
|
*/
|
|
321
321
|
declare const FUNCTYPE_MARKER: "@functype";
|
|
@@ -434,6 +434,128 @@ declare const createSerializationCompanion: <T>(reconstructor: (parsed: {
|
|
|
434
434
|
fromYAML: (yaml: string) => T;
|
|
435
435
|
fromBinary: (binary: string) => T;
|
|
436
436
|
};
|
|
437
|
+
declare namespace Serialization_d_exports {
|
|
438
|
+
export { JSONValue, deserialize, deserializeStrict, fromEnvelope, isFunctypeValue, serialize, toEnvelope };
|
|
439
|
+
}
|
|
440
|
+
/**
|
|
441
|
+
* The canonical JSON value type — anything `JSON.parse` can return and
|
|
442
|
+
* anything `JSON.stringify` can accept as input. Used by `toEnvelope` /
|
|
443
|
+
* `fromEnvelope` to express the contract precisely: the envelope is a
|
|
444
|
+
* structured JSON shape, not opaque `unknown`. Lets consumers wiring this
|
|
445
|
+
* API into another structured serializer (SuperJSON, DBOS custom
|
|
446
|
+
* transformers) slot it in without a cast at the boundary.
|
|
447
|
+
*
|
|
448
|
+
* Added in 1.2.2 — `toEnvelope`/`fromEnvelope` previously typed input/output
|
|
449
|
+
* as `unknown`, which forced a cast at the consumer side.
|
|
450
|
+
*/
|
|
451
|
+
type JSONValue = string | number | boolean | null | JSONValue[] | {
|
|
452
|
+
[key: string]: JSONValue;
|
|
453
|
+
};
|
|
454
|
+
/**
|
|
455
|
+
* Reconstruct any value from a JSON string. Lenient codec: walks the parsed
|
|
456
|
+
* structure and rebuilds any value carrying an `@functype` marker via the
|
|
457
|
+
* dispatch table; plain JSON without the marker walks through unchanged.
|
|
458
|
+
* Returns `Try` so malformed JSON or unknown markers are expressible values
|
|
459
|
+
* rather than thrown — matches the functype convention for expected-failure
|
|
460
|
+
* paths.
|
|
461
|
+
*
|
|
462
|
+
* **Pass-through policy:** valid JSON without an `@functype` marker is
|
|
463
|
+
* returned verbatim as `Success(value)`; only marker-carrying values are
|
|
464
|
+
* reconstructed. Only malformed JSON (or an unknown marker) yields `Failure`.
|
|
465
|
+
* For a strict variant that rejects unmarked input, see `deserializeStrict`.
|
|
466
|
+
*
|
|
467
|
+
* @example
|
|
468
|
+
* const result = Serialization.deserialize('{"@functype":"Either","_tag":"Right","value":5}')
|
|
469
|
+
* result.fold(e => console.error(e), v => console.log(v)) // → Right(5)
|
|
470
|
+
*
|
|
471
|
+
* // Plain (non-functype) values pass through:
|
|
472
|
+
* Serialization.deserialize('{"name":"alice","age":30}') // → Success({name, age})
|
|
473
|
+
*
|
|
474
|
+
* // Embedding in another structured serializer (SuperJSON, DBOS)? See
|
|
475
|
+
* // `fromEnvelope` — taking a string here forces the consumer through a
|
|
476
|
+
* // JSON.stringify shim and SuperJSON re-walks strings character-by-character.
|
|
477
|
+
*/
|
|
478
|
+
declare const deserialize: (json: string) => Try<unknown>;
|
|
479
|
+
/**
|
|
480
|
+
* Strict variant of `deserialize`: returns `Failure` when the parsed JSON
|
|
481
|
+
* doesn't carry an `@functype` marker at the top level. Use this at API,
|
|
482
|
+
* queue, or RPC boundaries where the wire format MUST be a functype value
|
|
483
|
+
* and pass-through silence would be a bug.
|
|
484
|
+
*
|
|
485
|
+
* Implementation note: only the top-level value is checked for the marker.
|
|
486
|
+
* Nested values inside it follow the same lenient pass-through rules as
|
|
487
|
+
* `deserialize` — a `Right` containing a plain object still reconstructs
|
|
488
|
+
* fine, you just can't START with a plain object.
|
|
489
|
+
*
|
|
490
|
+
* @example
|
|
491
|
+
* Serialization.deserializeStrict('{"@functype":"Option","_tag":"Some","value":1}') // → Success(Some(1))
|
|
492
|
+
* Serialization.deserializeStrict('{"_tag":"Some","value":1}') // → Failure
|
|
493
|
+
* Serialization.deserializeStrict('42') // → Failure
|
|
494
|
+
*/
|
|
495
|
+
declare const deserializeStrict: (json: string) => Try<unknown>;
|
|
496
|
+
/**
|
|
497
|
+
* Serialize any value to a JSON string. Lenient codec: thin convenience over
|
|
498
|
+
* `JSON.stringify` — functype instances self-stringify via their instance
|
|
499
|
+
* `toJSON()` method (which emits the `@functype`-marked envelope), and
|
|
500
|
+
* non-functype values pass through as plain JSON. Nested functype values
|
|
501
|
+
* embedded in plain objects/arrays serialize correctly via the standard
|
|
502
|
+
* JSON.stringify protocol with no walker needed.
|
|
503
|
+
*
|
|
504
|
+
* `undefined` is converted to `null` (matching the convention DBOS and
|
|
505
|
+
* SuperJSON use; `JSON.stringify(undefined)` returns the string `"undefined"`
|
|
506
|
+
* which is not valid JSON).
|
|
507
|
+
*/
|
|
508
|
+
declare const serialize: (value: unknown) => string;
|
|
509
|
+
/**
|
|
510
|
+
* Serialize a value to a parsed JSON envelope (object/array/primitive) rather
|
|
511
|
+
* than a string. Use this when nesting functype values inside another
|
|
512
|
+
* **structured** serializer (SuperJSON / DBOS custom transformers / similar)
|
|
513
|
+
* whose custom-transformer hook expects JSON values, not strings — passing a
|
|
514
|
+
* string to such a hook causes the host to re-walk it character-by-character,
|
|
515
|
+
* destroying the round-trip.
|
|
516
|
+
*
|
|
517
|
+
* Equivalent to `JSON.parse(serialize(value))` but exposed as a named entry
|
|
518
|
+
* point so consumers don't carry the parse/stringify shim.
|
|
519
|
+
*
|
|
520
|
+
* Returns `JSONValue` (tightened from `unknown` in 1.2.2) so consumers can
|
|
521
|
+
* drop the result straight into a host serializer's `serialize` hook without
|
|
522
|
+
* a boundary cast.
|
|
523
|
+
*
|
|
524
|
+
* @example
|
|
525
|
+
* // Inside a DBOS custom serialization recipe — zero casts:
|
|
526
|
+
* DBOS.registerSerialization({
|
|
527
|
+
* name: "functype",
|
|
528
|
+
* isApplicable: Serialization.isFunctypeValue,
|
|
529
|
+
* serialize: Serialization.toEnvelope,
|
|
530
|
+
* deserialize: (o) => Serialization.fromEnvelope(o).orThrow(),
|
|
531
|
+
* })
|
|
532
|
+
*/
|
|
533
|
+
declare const toEnvelope: (value: unknown) => JSONValue;
|
|
534
|
+
/**
|
|
535
|
+
* Inverse of `toEnvelope`: reconstruct any value from a parsed JSON envelope
|
|
536
|
+
* (object/array/primitive). Equivalent to `deserialize(JSON.stringify(envelope))`
|
|
537
|
+
* but skips the stringify/parse roundtrip — the same `revive` walker is
|
|
538
|
+
* applied directly. Returns `Try` for the same reasons as `deserialize`.
|
|
539
|
+
*
|
|
540
|
+
* Pass-through policy matches `deserialize`: a parsed value without an
|
|
541
|
+
* `@functype` marker is returned verbatim as `Success(value)`.
|
|
542
|
+
*
|
|
543
|
+
* Input is `unknown` (intentionally permissive — Postel's law). Host
|
|
544
|
+
* serializers typically hand the deserialize callback a JSON-shaped value
|
|
545
|
+
* that they parsed themselves, but their callback typing varies (some are
|
|
546
|
+
* `JSONValue`, some are `unknown`, some are `any`). Accepting `unknown`
|
|
547
|
+
* here means the function slots into any host shape without forcing a
|
|
548
|
+
* cast at the consumer site.
|
|
549
|
+
*/
|
|
550
|
+
declare const fromEnvelope: (envelope: unknown) => Try<unknown>;
|
|
551
|
+
/**
|
|
552
|
+
* Runtime guard: is this a live functype Serializable? Checks for the
|
|
553
|
+
* `serialize()` method plus the `_tag` field that every Serializable instance
|
|
554
|
+
* carries. Use this when wrapping `serialize`/`deserialize` in a host
|
|
555
|
+
* serializer that needs to distinguish functype values from foreign data
|
|
556
|
+
* (e.g. `isApplicable` in a DBOS recipe).
|
|
557
|
+
*/
|
|
558
|
+
declare const isFunctypeValue: (v: unknown) => v is Serializable<unknown>;
|
|
437
559
|
//#endregion
|
|
438
560
|
//#region src/typeclass/ContainerOps.d.ts
|
|
439
561
|
/**
|
|
@@ -2989,6 +3111,67 @@ interface IO<in out R extends Type, out E extends Type, out A extends Type> {
|
|
|
2989
3111
|
* @param delayMs - Delay between retries in milliseconds
|
|
2990
3112
|
*/
|
|
2991
3113
|
retryWithDelay(n: number, delayMs: number): IO<R, E, A>;
|
|
3114
|
+
/**
|
|
3115
|
+
* Retries the effect only while a predicate over the error holds.
|
|
3116
|
+
*
|
|
3117
|
+
* Useful for selective retry policies — e.g. retry HTTP 5xx but not 4xx,
|
|
3118
|
+
* retry network errors but not validation errors. The predicate is evaluated
|
|
3119
|
+
* BEFORE each retry; returning `false` short-circuits and re-fails with the
|
|
3120
|
+
* original error.
|
|
3121
|
+
*
|
|
3122
|
+
* @param opts.n - Maximum number of retry attempts.
|
|
3123
|
+
* @param opts.while - Predicate `(error, attempt) => boolean` (attempt is 1-indexed
|
|
3124
|
+
* for the first retry; if the predicate returns false, the retry is skipped).
|
|
3125
|
+
* @param opts.delayMs - Optional fixed delay between attempts.
|
|
3126
|
+
*
|
|
3127
|
+
* @example
|
|
3128
|
+
* ```ts
|
|
3129
|
+
* Http.get("/api/users", { decode })
|
|
3130
|
+
* .retryWhile({
|
|
3131
|
+
* n: 3,
|
|
3132
|
+
* while: (e) => e._tag === "HttpStatusError" && e.status >= 500,
|
|
3133
|
+
* delayMs: 250,
|
|
3134
|
+
* })
|
|
3135
|
+
* ```
|
|
3136
|
+
*/
|
|
3137
|
+
retryWhile(opts: {
|
|
3138
|
+
readonly n: number;
|
|
3139
|
+
readonly while: (error: E, attempt: number) => boolean;
|
|
3140
|
+
readonly delayMs?: number;
|
|
3141
|
+
}): IO<R, E, A>;
|
|
3142
|
+
/**
|
|
3143
|
+
* Retries the effect with exponential backoff and optional full jitter.
|
|
3144
|
+
*
|
|
3145
|
+
* Delay schedule: `min(maxMs, baseMs * factor^(attempt-1))`. With jitter
|
|
3146
|
+
* enabled, the actual delay is `computed * (0.5 + Math.random() * 0.5)`
|
|
3147
|
+
* (full jitter, 50–100% of the computed value) — prevents thundering herd.
|
|
3148
|
+
*
|
|
3149
|
+
* @param opts.n - Maximum number of retry attempts.
|
|
3150
|
+
* @param opts.baseMs - Initial delay before the first retry.
|
|
3151
|
+
* @param opts.maxMs - Cap on per-attempt delay. Defaults to 30_000.
|
|
3152
|
+
* @param opts.factor - Backoff multiplier per attempt. Defaults to 2.
|
|
3153
|
+
* @param opts.jitter - Apply full jitter (50–100% of computed delay). Defaults to true.
|
|
3154
|
+
* @param opts.while - Optional predicate `(error, attempt) => boolean` gating each retry.
|
|
3155
|
+
*
|
|
3156
|
+
* @example
|
|
3157
|
+
* ```ts
|
|
3158
|
+
* const isRetryable = (e: HttpError): boolean =>
|
|
3159
|
+
* e._tag === "NetworkError" ||
|
|
3160
|
+
* (e._tag === "HttpStatusError" && (e.status >= 500 || e.status === 429))
|
|
3161
|
+
*
|
|
3162
|
+
* Http.get("/api/users", { decode })
|
|
3163
|
+
* .retryWithBackoff({ n: 3, baseMs: 250, while: isRetryable })
|
|
3164
|
+
* .timeout(10_000)
|
|
3165
|
+
* ```
|
|
3166
|
+
*/
|
|
3167
|
+
retryWithBackoff(opts: {
|
|
3168
|
+
readonly n: number;
|
|
3169
|
+
readonly baseMs: number;
|
|
3170
|
+
readonly maxMs?: number;
|
|
3171
|
+
readonly factor?: number;
|
|
3172
|
+
readonly jitter?: boolean;
|
|
3173
|
+
readonly while?: (error: E, attempt: number) => boolean;
|
|
3174
|
+
}): IO<R, E, A>;
|
|
2992
3175
|
/**
|
|
2993
3176
|
* Sequences two IOs, keeping the second value.
|
|
2994
3177
|
*/
|
|
@@ -3712,6 +3895,16 @@ declare const HttpError: {
|
|
|
3712
3895
|
//#endregion
|
|
3713
3896
|
//#region src/fetch/HttpRequest.d.ts
|
|
3714
3897
|
type ParseMode = "json" | "text" | "blob" | "arrayBuffer" | "raw";
|
|
3898
|
+
/**
|
|
3899
|
+
* Typed query-parameter record. Scalar values (string | number | boolean) are
|
|
3900
|
+
* `String()`-coerced; arrays repeat the key (`{ tag: ["a", "b"] }` → `tag=a&tag=b`);
|
|
3901
|
+
* `undefined` and `null` values are dropped (so callers can write
|
|
3902
|
+
* `{ foo: maybe.toNullable() }` without conditionals); special characters are
|
|
3903
|
+
* percent-encoded via `URLSearchParams`.
|
|
3904
|
+
*
|
|
3905
|
+
* Nested objects are not supported (the type prevents them at compile time).
|
|
3906
|
+
*/
|
|
3907
|
+
type HttpQueryParams = Readonly<Record<string, string | number | boolean | readonly (string | number | boolean)[] | undefined | null>>;
|
|
3715
3908
|
interface HttpRequestOptions<T = unknown> {
|
|
3716
3909
|
readonly url: string;
|
|
3717
3910
|
readonly method: HttpMethod;
|
|
@@ -3719,6 +3912,11 @@ interface HttpRequestOptions<T = unknown> {
|
|
|
3719
3912
|
readonly body?: unknown;
|
|
3720
3913
|
readonly signal?: AbortSignal;
|
|
3721
3914
|
readonly parseAs?: ParseMode;
|
|
3915
|
+
/**
|
|
3916
|
+
* Query-string parameters appended to the URL. Merges with any query string
|
|
3917
|
+
* already present in `url`. See {@link HttpQueryParams} for encoding rules.
|
|
3918
|
+
*/
|
|
3919
|
+
readonly params?: HttpQueryParams;
|
|
3722
3920
|
/**
|
|
3723
3921
|
* Either-returning response decoder. Returns `Left(DecoderError)` on
|
|
3724
3922
|
* failure; the framework maps that to `HttpError.DecodeError(cause: DecoderError)`.
|
|
@@ -3760,6 +3958,10 @@ interface HttpMethodOptions<T = unknown> {
|
|
|
3760
3958
|
/** @deprecated Use `decode` (Either-returning) or an adapter package for throw-pattern validators. */
|
|
3761
3959
|
readonly validate?: (data: unknown) => T;
|
|
3762
3960
|
readonly flatten?: boolean;
|
|
3961
|
+
/**
|
|
3962
|
+
* Query-string parameters appended to the URL. See {@link HttpQueryParams}.
|
|
3963
|
+
*/
|
|
3964
|
+
readonly params?: HttpQueryParams;
|
|
3763
3965
|
}
|
|
3764
3966
|
interface HttpResponse<T> {
|
|
3765
3967
|
readonly data: T;
|
|
@@ -3827,6 +4029,40 @@ interface HttpClientConfig {
|
|
|
3827
4029
|
* ```
|
|
3828
4030
|
*/
|
|
3829
4031
|
readonly beforeRequest?: (request: HttpRequestView) => IO<never, HttpError, HttpRequestView>;
|
|
4032
|
+
/**
|
|
4033
|
+
* Effectful transformer that runs after the response is parsed (and the
|
|
4034
|
+
* decoder, if any, succeeds) but before the IO resolves to the caller.
|
|
4035
|
+
* Returning a failed IO surfaces the error in place of the response.
|
|
4036
|
+
*
|
|
4037
|
+
* **Only runs on the success path.** `HttpStatusError` (non-2xx),
|
|
4038
|
+
* `DecodeError` (validation failure), and `NetworkError` (fetch / abort)
|
|
4039
|
+
* skip this hook and surface directly. For *error*-side observability and
|
|
4040
|
+
* recovery (refresh-on-401, error logging), use `.catchTag(...)` /
|
|
4041
|
+
* `.tapError(...)` at the call site.
|
|
4042
|
+
*
|
|
4043
|
+
* The hook receives `HttpResponse<unknown>` — body shape is opaque here
|
|
4044
|
+
* because hooks are response-shape-agnostic. The per-call decoder narrows
|
|
4045
|
+
* `data` to the typed value before the response reaches the caller, but
|
|
4046
|
+
* the hook itself sees `unknown`.
|
|
4047
|
+
*
|
|
4048
|
+
* @example
|
|
4049
|
+
* ```ts
|
|
4050
|
+
* const api = Http.client({
|
|
4051
|
+
* baseUrl: "https://api.example.com",
|
|
4052
|
+
* afterResponse: (response) =>
|
|
4053
|
+
* IO.succeed(response)
|
|
4054
|
+
* .tap((r) => logger.info("response", { status: r.status }))
|
|
4055
|
+
* .map((r) => ({ ...r, headers: redactSensitiveHeaders(r.headers) })),
|
|
4056
|
+
* })
|
|
4057
|
+
*
|
|
4058
|
+
* // Refresh-on-401 is a .catchTag pattern, NOT an afterResponse pattern:
|
|
4059
|
+
* api.get("/me", { decode })
|
|
4060
|
+
* .catchTag("HttpStatusError", (e) =>
|
|
4061
|
+
* e.status === 401 ? refreshToken().flatMap(() => api.get("/me", { decode })) : IO.fail(e),
|
|
4062
|
+
* )
|
|
4063
|
+
* ```
|
|
4064
|
+
*/
|
|
4065
|
+
readonly afterResponse?: (response: HttpResponse<unknown>) => IO<never, HttpError, HttpResponse<unknown>>;
|
|
3830
4066
|
}
|
|
3831
4067
|
declare const HttpClient: Tag<HttpClientConfig>;
|
|
3832
4068
|
//#endregion
|
|
@@ -4166,7 +4402,7 @@ interface Lazy<out T extends Type> extends FunctypeBase<T, "Lazy">, Extractable<
|
|
|
4166
4402
|
* `SerializedError` for the wire).
|
|
4167
4403
|
*
|
|
4168
4404
|
* Changed in 1.2.0 — pre-1.2.0 Lazy emitted `{_tag, evaluated, value?}`
|
|
4169
|
-
* without forcing. See `docs/proposals/serializable-audit-q1-q2.md`.
|
|
4405
|
+
* without forcing. See `docs/archive/proposals/serializable-audit-q1-q2.md`.
|
|
4170
4406
|
*/
|
|
4171
4407
|
toValue(): {
|
|
4172
4408
|
_tag: "Lazy";
|
|
@@ -4696,105 +4932,6 @@ declare const Ref: (<A extends Type>(initial: A) => Ref<A>) & {
|
|
|
4696
4932
|
*/
|
|
4697
4933
|
of: <A extends Type>(initial: A) => Ref<A>;
|
|
4698
4934
|
};
|
|
4699
|
-
declare namespace Serialization_d_exports {
|
|
4700
|
-
export { deserialize, deserializeStrict, fromEnvelope, isFunctypeValue, serialize, toEnvelope };
|
|
4701
|
-
}
|
|
4702
|
-
/**
|
|
4703
|
-
* Reconstruct any value from a JSON string. Lenient codec: walks the parsed
|
|
4704
|
-
* structure and rebuilds any value carrying an `@functype` marker via the
|
|
4705
|
-
* dispatch table; plain JSON without the marker walks through unchanged.
|
|
4706
|
-
* Returns `Try` so malformed JSON or unknown markers are expressible values
|
|
4707
|
-
* rather than thrown — matches the functype convention for expected-failure
|
|
4708
|
-
* paths.
|
|
4709
|
-
*
|
|
4710
|
-
* **Pass-through policy:** valid JSON without an `@functype` marker is
|
|
4711
|
-
* returned verbatim as `Success(value)`; only marker-carrying values are
|
|
4712
|
-
* reconstructed. Only malformed JSON (or an unknown marker) yields `Failure`.
|
|
4713
|
-
* For a strict variant that rejects unmarked input, see `deserializeStrict`.
|
|
4714
|
-
*
|
|
4715
|
-
* @example
|
|
4716
|
-
* const result = Serialization.deserialize('{"@functype":"Either","_tag":"Right","value":5}')
|
|
4717
|
-
* result.fold(e => console.error(e), v => console.log(v)) // → Right(5)
|
|
4718
|
-
*
|
|
4719
|
-
* // Plain (non-functype) values pass through:
|
|
4720
|
-
* Serialization.deserialize('{"name":"alice","age":30}') // → Success({name, age})
|
|
4721
|
-
*
|
|
4722
|
-
* // Embedding in another structured serializer (SuperJSON, DBOS)? See
|
|
4723
|
-
* // `fromEnvelope` — taking a string here forces the consumer through a
|
|
4724
|
-
* // JSON.stringify shim and SuperJSON re-walks strings character-by-character.
|
|
4725
|
-
*/
|
|
4726
|
-
declare const deserialize: (json: string) => Try<unknown>;
|
|
4727
|
-
/**
|
|
4728
|
-
* Strict variant of `deserialize`: returns `Failure` when the parsed JSON
|
|
4729
|
-
* doesn't carry an `@functype` marker at the top level. Use this at API,
|
|
4730
|
-
* queue, or RPC boundaries where the wire format MUST be a functype value
|
|
4731
|
-
* and pass-through silence would be a bug.
|
|
4732
|
-
*
|
|
4733
|
-
* Implementation note: only the top-level value is checked for the marker.
|
|
4734
|
-
* Nested values inside it follow the same lenient pass-through rules as
|
|
4735
|
-
* `deserialize` — a `Right` containing a plain object still reconstructs
|
|
4736
|
-
* fine, you just can't START with a plain object.
|
|
4737
|
-
*
|
|
4738
|
-
* @example
|
|
4739
|
-
* Serialization.deserializeStrict('{"@functype":"Option","_tag":"Some","value":1}') // → Success(Some(1))
|
|
4740
|
-
* Serialization.deserializeStrict('{"_tag":"Some","value":1}') // → Failure
|
|
4741
|
-
* Serialization.deserializeStrict('42') // → Failure
|
|
4742
|
-
*/
|
|
4743
|
-
declare const deserializeStrict: (json: string) => Try<unknown>;
|
|
4744
|
-
/**
|
|
4745
|
-
* Serialize any value to a JSON string. Lenient codec: thin convenience over
|
|
4746
|
-
* `JSON.stringify` — functype instances self-stringify via their instance
|
|
4747
|
-
* `toJSON()` method (which emits the `@functype`-marked envelope), and
|
|
4748
|
-
* non-functype values pass through as plain JSON. Nested functype values
|
|
4749
|
-
* embedded in plain objects/arrays serialize correctly via the standard
|
|
4750
|
-
* JSON.stringify protocol with no walker needed.
|
|
4751
|
-
*
|
|
4752
|
-
* `undefined` is converted to `null` (matching the convention DBOS and
|
|
4753
|
-
* SuperJSON use; `JSON.stringify(undefined)` returns the string `"undefined"`
|
|
4754
|
-
* which is not valid JSON).
|
|
4755
|
-
*/
|
|
4756
|
-
declare const serialize: (value: unknown) => string;
|
|
4757
|
-
/**
|
|
4758
|
-
* Serialize a value to a parsed JSON envelope (object/array/primitive) rather
|
|
4759
|
-
* than a string. Use this when nesting functype values inside another
|
|
4760
|
-
* **structured** serializer (SuperJSON / DBOS custom transformers / similar)
|
|
4761
|
-
* whose custom-transformer hook expects JSON values, not strings — passing a
|
|
4762
|
-
* string to such a hook causes the host to re-walk it character-by-character,
|
|
4763
|
-
* destroying the round-trip.
|
|
4764
|
-
*
|
|
4765
|
-
* Equivalent to `JSON.parse(serialize(value))` but exposed as a named entry
|
|
4766
|
-
* point so consumers don't carry the parse/stringify shim. The output is
|
|
4767
|
-
* pure JSON (object, array, string, number, boolean, or null) — typed as
|
|
4768
|
-
* `unknown` for honesty (TS can't statically prove "JSON-shaped").
|
|
4769
|
-
*
|
|
4770
|
-
* @example
|
|
4771
|
-
* // Inside a DBOS custom serialization recipe:
|
|
4772
|
-
* DBOS.registerSerialization({
|
|
4773
|
-
* name: "functype",
|
|
4774
|
-
* isApplicable: Serialization.isFunctypeValue,
|
|
4775
|
-
* serialize: Serialization.toEnvelope,
|
|
4776
|
-
* deserialize: (o) => Serialization.fromEnvelope(o).orThrow(),
|
|
4777
|
-
* })
|
|
4778
|
-
*/
|
|
4779
|
-
declare const toEnvelope: (value: unknown) => unknown;
|
|
4780
|
-
/**
|
|
4781
|
-
* Inverse of `toEnvelope`: reconstruct any value from a parsed JSON envelope
|
|
4782
|
-
* (object/array/primitive). Equivalent to `deserialize(JSON.stringify(envelope))`
|
|
4783
|
-
* but skips the stringify/parse roundtrip — the same `revive` walker is
|
|
4784
|
-
* applied directly. Returns `Try` for the same reasons as `deserialize`.
|
|
4785
|
-
*
|
|
4786
|
-
* Pass-through policy matches `deserialize`: a parsed value without an
|
|
4787
|
-
* `@functype` marker is returned verbatim as `Success(value)`.
|
|
4788
|
-
*/
|
|
4789
|
-
declare const fromEnvelope: (envelope: unknown) => Try<unknown>;
|
|
4790
|
-
/**
|
|
4791
|
-
* Runtime guard: is this a live functype Serializable? Checks for the
|
|
4792
|
-
* `serialize()` method plus the `_tag` field that every Serializable instance
|
|
4793
|
-
* carries. Use this when wrapping `serialize`/`deserialize` in a host
|
|
4794
|
-
* serializer that needs to distinguish functype values from foreign data
|
|
4795
|
-
* (e.g. `isApplicable` in a DBOS recipe).
|
|
4796
|
-
*/
|
|
4797
|
-
declare const isFunctypeValue: (v: unknown) => v is Serializable<unknown>;
|
|
4798
4935
|
//#endregion
|
|
4799
4936
|
//#region src/set/Set.d.ts
|
|
4800
4937
|
/**
|
|
@@ -5831,4 +5968,4 @@ interface FailureErrorType extends Error {
|
|
|
5831
5968
|
}
|
|
5832
5969
|
declare const FailureError: (cause: Error, message?: string) => FailureErrorType;
|
|
5833
5970
|
//#endregion
|
|
5834
|
-
export {
|
|
5971
|
+
export { Kind as $, reduceWiden as $n, TaskErrorInfo as $t, Collection as A, Cond as An, LayerError as At, Ref as B, NonEmptyString as Bn, FieldValidation as Bt, isRight as C, isTaggedThrowable as Cn, serializeError as Cr, IO as Ct, Functype as D, Base as Dn, DoResult as Dr, TimeoutError as Dt, FunctypeSum as E, ThrowableType as En, isExtractable as Er, Task as Et, Some as F, BoundedNumber as Fn, Context as Ft, ESMapType as G, UUID as Gn, ErrorCode as Gt, Matchable as H, PatternString as Hn, Validation as Ht, Stack as I, BoundedString as In, ContextServices as It, Traversable as J, ValidatedBrandCompanion as Jn, TypedError as Jt, Map$1 as K, UrlString as Kn, ErrorMessage as Kt, Valuable as L, EmailAddress as Ln, HasService as Lt, None as M, InstanceType as Mn, LayerOutput as Mt, Option as N, isCompanion as Nn, Exit as Nt, FunctypeBase as O, Match as On, Doable as Or, UIO as Ot, OptionConstructor as P, Companion as Pn, ExitTag as Pt, HKT as Q, reduceRightWiden as Qn, ErrorWithTaskInfo as Qt, ValuableParams as R, ISO8601Date as Rn, Tag as Rt, isLeft as S, createCancellationTokenSource as Sn, deserializeError as Sr, TestContext as St, tryCatchAsync as T, Throwable as Tn, Extractable as Tr, RIO as Tt, MatchableUtils as U, PositiveInteger as Un, ValidationRule as Ut, Obj as V, NonNegativeNumber as Vn, FormValidation as Vt, ESMap as W, PositiveNumber as Wn, Validator as Wt, Identity as X, TypeNames as Xn, ErrorChainElement as Xt, Lazy as Y, Try as Yn, TypedErrorContext as Yt, EitherKind as Z, Widen as Zn, ErrorFormatterOptions as Zt, Right as _, TaskMetadata as _n, fromBinary as _r, HttpStatusError as _t, EmptyListError as a, DecoderError as an, CollectionOps as ar, Http as at, TypeCheckLeft as b, TaskResult as bn, taggedEnvelope as br, TestClock as bt, LeftError as c, Async as cn, Serialization_d_exports as cr, HttpMethodOptions as ct, isDoCapable as d, Err as dn, SerializationResult as dr, HttpRequestView as dt, createErrorSerializer as en, Promisable as er, ListKind as et, unwrap as f, Ok as fn, createCustomSerializer as fr, HttpResponse as ft, LeftOf as g, TaskFailure as gn, envelope as gr, HttpMethod as gt, Left as h, Task$1 as hn, createTaggedSerializer as hr, HttpError as ht, DoGenerator as i, Decoder as in, Monad as ir, FoldableUtils as it, List as j, CompanionMethods as jn, LayerInput as jt, FunctypeCollection as k, UntypedMatch as kn, ParseError as kr, Layer as kt, LeftErrorType as l, CancellationToken as ln, FUNCTYPE_MARKER as lr, HttpQueryParams as lt, EitherBase as m, TaggedThrowable as mn, createSerializer as mr, DecodeError as mt, Do as n, formatStackTrace as nn, AsyncMonad as nr, TryKind as nt, FailureError as o, DecoderErrorComposite as on, ContainerOps as or, HttpClient as ot, Either as p, Sync as pn, createSerializationCompanion as pr, ParseMode as pt, KVTraversable as q, ValidatedBrand as qn, ErrorStatus as qt, DoAsync as r, safeStringify as rn, Functor as rr, UniversalContainer as rt, FailureErrorType as s, DecoderErrorLeaf as sn, JSONValue as sr, HttpClientConfig as st, $ as t, formatError as tn, Applicative as tr, OptionKind as tt, NoneError as u, CancellationTokenSource as un, FunctypeEnvelope as ur, HttpRequestOptions as ut, RightOf as v, TaskOutcome as vn, fromJSON as vr, NetworkError as vt, tryCatch as w, NAME as wn, LazyList as wr, InterruptedError as wt, TypeCheckRight as x, TaskSuccess as xn, SerializedError as xr, TestClockTag as xt, TestEither as y, TaskParams as yn, fromYAML as yr, ResponseDecodeError as yt, Set as z, IntegerNumber as zn, TagService as zt };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { a as ExtractBrand, c as hasBrand, i as BrandedString, l as unwrapBrand, n as BrandedBoolean, o as Unwrap, r as BrandedNumber, s as createBrander, t as Brand } from "./Brand-bfnGXuum.js";
|
|
2
|
-
import { $ as
|
|
2
|
+
import { $ as Kind, $n as reduceWiden, $t as TaskErrorInfo, A as Collection, An as Cond, At as LayerError, B as Ref, Bn as NonEmptyString, Bt as FieldValidation, C as isRight, Cn as isTaggedThrowable, Cr as serializeError, Ct as IO, D as Functype, Dn as Base, Dr as DoResult, Dt as TimeoutError, E as FunctypeSum, En as ThrowableType, Er as isExtractable, Et as Task, F as Some, Fn as BoundedNumber, Ft as Context, G as ESMapType, Gn as UUID, Gt as ErrorCode, H as Matchable, Hn as PatternString, Ht as Validation, I as Stack, In as BoundedString, It as ContextServices, J as Traversable, Jn as ValidatedBrandCompanion, Jt as TypedError, K as Map, Kn as UrlString, Kt as ErrorMessage, L as Valuable, Ln as EmailAddress, Lt as HasService, M as None, Mn as InstanceType, Mt as LayerOutput, N as Option, Nn as isCompanion, Nt as Exit, O as FunctypeBase, On as Match, Or as Doable, Ot as UIO, P as OptionConstructor, Pn as Companion, Pt as ExitTag, Q as HKT, Qn as reduceRightWiden, Qt as ErrorWithTaskInfo, R as ValuableParams, Rn as ISO8601Date, Rt as Tag, S as isLeft, Sn as createCancellationTokenSource, Sr as deserializeError, St as TestContext, T as tryCatchAsync, Tn as Throwable, Tr as Extractable, Tt as RIO, U as MatchableUtils, Un as PositiveInteger, Ut as ValidationRule, V as Obj, Vn as NonNegativeNumber, Vt as FormValidation, W as ESMap, Wn as PositiveNumber, Wt as Validator, X as Identity, Xn as TypeNames, Xt as ErrorChainElement, Y as Lazy, Yn as Try, Yt as TypedErrorContext, Z as EitherKind, Zn as Widen, Zt as ErrorFormatterOptions, _ as Right, _n as TaskMetadata, _r as fromBinary, _t as HttpStatusError, a as EmptyListError, an as DecoderError, ar as CollectionOps, at as Http, b as TypeCheckLeft, bn as TaskResult, br as taggedEnvelope, bt as TestClock, c as LeftError, cn as Async, cr as Serialization_d_exports, ct as HttpMethodOptions, d as isDoCapable, dn as Err, dr as SerializationResult, dt as HttpRequestView, en as createErrorSerializer, er as Promisable, et as ListKind, f as unwrap, fn as Ok, fr as createCustomSerializer, ft as HttpResponse, g as LeftOf, gn as TaskFailure, gr as envelope, gt as HttpMethod, h as Left, hn as Task$1, hr as createTaggedSerializer, ht as HttpError, i as DoGenerator, in as Decoder, ir as Monad, it as FoldableUtils, j as List, jn as CompanionMethods, jt as LayerInput, k as FunctypeCollection, kn as UntypedMatch, kr as ParseError, kt as Layer, l as LeftErrorType, ln as CancellationToken, lr as FUNCTYPE_MARKER, lt as HttpQueryParams, m as EitherBase, mn as TaggedThrowable, mr as createSerializer, mt as DecodeError, n as Do, nn as formatStackTrace, nr as AsyncMonad, nt as TryKind, o as FailureError, on as DecoderErrorComposite, or as ContainerOps, ot as HttpClient, p as Either, pn as Sync, pr as createSerializationCompanion, pt as ParseMode, q as KVTraversable, qn as ValidatedBrand, qt as ErrorStatus, r as DoAsync, rn as safeStringify, rr as Functor, rt as UniversalContainer, s as FailureErrorType, sn as DecoderErrorLeaf, sr as JSONValue, st as HttpClientConfig, t as $, tn as formatError, tr as Applicative, tt as OptionKind, u as NoneError, un as CancellationTokenSource, ur as FunctypeEnvelope, ut as HttpRequestOptions, v as RightOf, vn as TaskOutcome, vr as fromJSON, vt as NetworkError, w as tryCatch, wn as NAME, wr as LazyList, wt as InterruptedError, x as TypeCheckRight, xn as TaskSuccess, xr as SerializedError, xt as TestClockTag, y as TestEither, yn as TaskParams, yr as fromYAML, yt as ResponseDecodeError, z as Set, zn as IntegerNumber, zt as TagService } from "./index-DBYBJg-D.js";
|
|
3
3
|
import { a as isTypeable, c as SerializationMethods, d as Type, i as TypeableParams, l as Pipe, n as ExtractTag, o as Serializable, r as Typeable, s as SerializableEnvelope, t as Tuple, u as Foldable } from "./Tuple-8yRldBty.js";
|
|
4
|
-
|
|
4
|
+
import { t as Logger } from "./Logger-75yEf2wp.js";
|
|
5
|
+
export { $, type Applicative, Async, type AsyncMonad, Base, BoundedNumber, BoundedString, Brand, BrandedBoolean, type BrandedBoolean as BrandedBooleanType, BrandedNumber, type BrandedNumber as BrandedNumberType, BrandedString, type BrandedString as BrandedStringType, CancellationToken, CancellationTokenSource, Collection, type CollectionOps, Companion, CompanionMethods, Cond, type ContainerOps, Context, type Context as ContextType, type ContextServices, type DecodeError, Decoder, DecoderError, type DecoderErrorComposite, type DecoderErrorLeaf, Do, DoAsync, DoGenerator, type DoResult, type Doable, ESMap, ESMapType, Either, EitherBase, EitherKind, EmailAddress, EmptyListError, Err, ErrorChainElement, ErrorCode, ErrorFormatterOptions, ErrorMessage, ErrorStatus, ErrorWithTaskInfo, Exit, type Exit as ExitType, type ExitTag, type ExtractBrand, ExtractTag, type Extractable, FUNCTYPE_MARKER, FailureError, FailureErrorType, FieldValidation, Foldable, FoldableUtils, FormValidation, type Functor, Functype, FunctypeBase, FunctypeCollection, FunctypeEnvelope, FunctypeSum, HKT, type HasService, Http, HttpClient, type HttpClientConfig, type HttpError, HttpError as HttpErrors, type HttpMethod, type HttpMethodOptions, type HttpQueryParams, type HttpRequestOptions, type HttpRequestView, type HttpResponse, type HttpStatusError, IO, type IO as IOType, type Task as IOTask, ISO8601Date, Identity, InstanceType, IntegerNumber, InterruptedError, type JSONValue, KVTraversable, Kind, Layer, type Layer as LayerType, type LayerError, type LayerInput, type LayerOutput, Lazy, type Lazy as LazyType, LazyList, Left, LeftError, LeftErrorType, LeftOf, List, ListKind, Logger, Map, Match, type Matchable, MatchableUtils, type Monad, NAME, type NetworkError, NonEmptyString, NonNegativeNumber, None, NoneError, Obj, Ok, Option, OptionConstructor, OptionKind, ParseError, type ParseMode, PatternString, Pipe, PositiveInteger, PositiveNumber, type Promisable, type RIO, Ref, type Ref as RefType, type ResponseDecodeError, Right, RightOf, Serializable, SerializableEnvelope, Serialization_d_exports as Serialization, SerializationMethods, SerializationResult, SerializedError, Set, Some, Stack, Sync, Tag, type Tag as TagType, type TagService, TaggedThrowable, Task$1 as Task, TaskErrorInfo, TaskFailure, TaskMetadata, TaskOutcome, TaskParams, TaskResult, TaskSuccess, TestClock, type TestClock as TestClockType, TestClockTag, TestContext, type TestContext as TestContextType, TestEither, Throwable, ThrowableType, TimeoutError, Traversable, Try, TryKind, Tuple, Type, TypeCheckLeft, TypeCheckRight, TypeNames, Typeable, TypeableParams, TypedError, TypedErrorContext, type UIO, UUID, UniversalContainer, UntypedMatch, type Unwrap, UrlString, ValidatedBrand, type ValidatedBrand as ValidatedBrandType, type ValidatedBrandCompanion, Validation, ValidationRule, Validator, Valuable, ValuableParams, type Widen, createBrander, createCancellationTokenSource, createCustomSerializer, createErrorSerializer, createSerializationCompanion, createSerializer, createTaggedSerializer, deserializeError, envelope, formatError, formatStackTrace, fromBinary, fromJSON, fromYAML, hasBrand, isCompanion, isDoCapable, isExtractable, isLeft, isRight, isTaggedThrowable, isTypeable, reduceRightWiden, reduceWiden, safeStringify, serializeError, taggedEnvelope, tryCatch, tryCatchAsync, unwrap, unwrapBrand };
|
package/dist/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{Brand as e,BrandedBoolean as t,BrandedNumber as n,BrandedString as r,createBrander as i,hasBrand as a,unwrap as o}from"./branded/index.js";import{
|
|
1
|
+
import{Brand as e,BrandedBoolean as t,BrandedNumber as n,BrandedString as r,createBrander as i,hasBrand as a,unwrap as o}from"./branded/index.js";import{a as s,c,d as l,i as u,l as d,n as f,o as p,p as m,r as h,s as g,t as _,u as v}from"./Tuple-knEoDiKZ.js";import{$ as y,A as b,At as x,B as S,C,Ct as w,D as T,Dt as E,E as D,Et as O,F as k,Ft as A,G as j,H as M,I as N,It as P,J as F,K as I,L,Lt as R,M as z,Mt as B,N as V,Nt as H,O as U,Ot as W,P as G,Pt as K,Q as q,R as J,S as Y,St as X,T as Z,Tt as Q,U as $,V as ee,W as te,X as ne,Y as re,Z as ie,_ as ae,_t as oe,a as se,at as ce,b as le,bt as ue,c as de,ct as fe,d as pe,dt as me,et as he,f as ge,ft as _e,g as ve,gt as ye,h as be,ht as xe,i as Se,it as Ce,j as we,jt as Te,k as Ee,kt as De,l as Oe,lt as ke,m as Ae,mt as je,n as Me,nt as Ne,o as Pe,ot as Fe,p as Ie,pt as Le,q as Re,r as ze,rt as Be,s as Ve,st as He,t as Ue,tt as We,u as Ge,ut as Ke,v as qe,vt as Je,w as Ye,wt as Xe,x as Ze,xt as Qe,y as $e,yt as et,z as tt}from"./src-P2lgP6cJ.js";export{we as $,ie as Base,We as BoundedNumber,Ne as BoundedString,e as Brand,t as BrandedBoolean,n as BrandedNumber,r as BrandedString,m as Companion,y as Cond,Y as Context,S as Decoder,ee as DecoderError,z as Do,V as DoAsync,$ as ESMap,je as Either,Be as EmailAddress,G as EmptyListError,te as Err,Ze as Exit,f as FUNCTYPE_MARKER,k as FailureError,Oe as FoldableUtils,de as HKT,Ge as Http,ge as HttpClient,pe as HttpErrors,qe as IO,Ce as ISO8601Date,Ve as Identity,ce as IntegerNumber,$e as InterruptedError,ae as Layer,Pe as Lazy,E as LazyList,xe as Left,N as LeftError,w as List,M as Map,q as Match,se as MatchableUtils,re as NAME,Fe as NonEmptyString,He as NonNegativeNumber,B as None,L as NoneError,Se as Obj,j as Ok,H as Option,K as OptionConstructor,D as ParseError,fe as PatternString,ke as PositiveInteger,Ke as PositiveNumber,W as Ref,ye as Right,Me as Serialization,De as Set,A as Some,ze as Stack,ve as Tag,I as Task,Ie as TestClock,Ae as TestClockTag,be as TestContext,ne as Throwable,le as TimeoutError,O as Try,_ as Tuple,oe as TypeCheckLeft,Je as TypeCheckRight,Xe as Typeable,Z as TypedError,me as UUID,_e as UrlString,Le as ValidatedBrand,Ye as Validation,Ue as Valuable,i as createBrander,Re as createCancellationTokenSource,h as createCustomSerializer,T as createErrorSerializer,u as createSerializationCompanion,s as createSerializer,p as createTaggedSerializer,P as deserializeError,g as envelope,U as formatError,Ee as formatStackTrace,c as fromBinary,d as fromJSON,v as fromYAML,a as hasBrand,he as isCompanion,J as isDoCapable,C as isExtractable,et as isLeft,ue as isRight,F as isTaggedThrowable,Q as isTypeable,x as reduceRightWiden,Te as reduceWiden,b as safeStringify,R as serializeError,l as taggedEnvelope,Qe as tryCatch,X as tryCatchAsync,tt as unwrap,o as unwrapBrand};
|
package/dist/list/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { j as List } from "../index-
|
|
1
|
+
import { j as List } from "../index-DBYBJg-D.js";
|
|
2
2
|
export { List };
|
package/dist/list/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{Ct as e}from"../src-P2lgP6cJ.js";export{e as List};
|
|
File without changes
|
package/dist/map/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { K as Map } from "../index-DBYBJg-D.js";
|
|
2
2
|
export { Map };
|
package/dist/map/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{H as e}from"../src-P2lgP6cJ.js";export{e as Map};
|
package/dist/option/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { F as Some, M as None, N as Option, P as OptionConstructor } from "../index-
|
|
1
|
+
import { F as Some, M as None, N as Option, P as OptionConstructor } from "../index-DBYBJg-D.js";
|
|
2
2
|
export { None, Option, OptionConstructor, Some };
|
package/dist/option/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{Ft as e,Mt as t,Nt as n,Pt as r}from"../src-P2lgP6cJ.js";export{t as None,n as Option,r as OptionConstructor,e as Some};
|
package/dist/set/index.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { z as Set } from "../index-
|
|
1
|
+
import { z as Set } from "../index-DBYBJg-D.js";
|
|
2
2
|
export { Set };
|
package/dist/set/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{kt as e}from"../src-P2lgP6cJ.js";export{e as Set};
|