effect 4.0.0-beta.69 → 4.0.0-beta.70
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/Array.d.ts +454 -0
- package/dist/Array.d.ts.map +1 -1
- package/dist/Array.js +152 -0
- package/dist/Array.js.map +1 -1
- package/dist/BigDecimal.d.ts +87 -33
- package/dist/BigDecimal.d.ts.map +1 -1
- package/dist/BigDecimal.js +37 -11
- package/dist/BigDecimal.js.map +1 -1
- package/dist/BigInt.d.ts +71 -14
- package/dist/BigInt.d.ts.map +1 -1
- package/dist/BigInt.js +35 -10
- package/dist/BigInt.js.map +1 -1
- package/dist/Boolean.d.ts +4 -0
- package/dist/Boolean.d.ts.map +1 -1
- package/dist/Boolean.js +4 -0
- package/dist/Boolean.js.map +1 -1
- package/dist/Brand.d.ts +16 -11
- package/dist/Brand.d.ts.map +1 -1
- package/dist/Brand.js +16 -11
- package/dist/Brand.js.map +1 -1
- package/dist/Cache.d.ts +13 -1
- package/dist/Cache.d.ts.map +1 -1
- package/dist/Cache.js +8 -0
- package/dist/Cache.js.map +1 -1
- package/dist/Cause.d.ts +95 -3
- package/dist/Cause.d.ts.map +1 -1
- package/dist/Cause.js +56 -2
- package/dist/Cause.js.map +1 -1
- package/dist/Channel.d.ts +312 -0
- package/dist/Channel.d.ts.map +1 -1
- package/dist/Channel.js +126 -0
- package/dist/Channel.js.map +1 -1
- package/dist/ChannelSchema.d.ts +20 -0
- package/dist/ChannelSchema.d.ts.map +1 -1
- package/dist/ChannelSchema.js +12 -0
- package/dist/ChannelSchema.js.map +1 -1
- package/dist/Chunk.d.ts +59 -22
- package/dist/Chunk.d.ts.map +1 -1
- package/dist/Chunk.js +29 -10
- package/dist/Chunk.js.map +1 -1
- package/dist/Combiner.d.ts +75 -71
- package/dist/Combiner.d.ts.map +1 -1
- package/dist/Combiner.js +67 -62
- package/dist/Combiner.js.map +1 -1
- package/dist/Config.d.ts +167 -46
- package/dist/Config.d.ts.map +1 -1
- package/dist/Config.js +108 -28
- package/dist/Config.js.map +1 -1
- package/dist/ConfigProvider.d.ts +235 -158
- package/dist/ConfigProvider.d.ts.map +1 -1
- package/dist/ConfigProvider.js +144 -93
- package/dist/ConfigProvider.js.map +1 -1
- package/dist/Console.d.ts +21 -79
- package/dist/Console.d.ts.map +1 -1
- package/dist/Console.js +20 -75
- package/dist/Console.js.map +1 -1
- package/dist/Context.d.ts +4 -4
- package/dist/Context.js +2 -2
- package/dist/Cron.d.ts +42 -16
- package/dist/Cron.d.ts.map +1 -1
- package/dist/Cron.js +33 -13
- package/dist/Cron.js.map +1 -1
- package/dist/Crypto.d.ts +6 -0
- package/dist/Crypto.d.ts.map +1 -1
- package/dist/Crypto.js.map +1 -1
- package/dist/Data.d.ts +132 -70
- package/dist/Data.d.ts.map +1 -1
- package/dist/Data.js +44 -29
- package/dist/Data.js.map +1 -1
- package/dist/DateTime.d.ts +227 -14
- package/dist/DateTime.d.ts.map +1 -1
- package/dist/DateTime.js +115 -6
- package/dist/DateTime.js.map +1 -1
- package/dist/Deferred.d.ts +94 -27
- package/dist/Deferred.d.ts.map +1 -1
- package/dist/Deferred.js +33 -8
- package/dist/Deferred.js.map +1 -1
- package/dist/Differ.d.ts +2 -0
- package/dist/Differ.d.ts.map +1 -1
- package/dist/Duration.d.ts +64 -6
- package/dist/Duration.d.ts.map +1 -1
- package/dist/Duration.js +26 -2
- package/dist/Duration.js.map +1 -1
- package/dist/Effect.d.ts +907 -603
- package/dist/Effect.d.ts.map +1 -1
- package/dist/Effect.js +360 -233
- package/dist/Effect.js.map +1 -1
- package/dist/Effectable.d.ts +3 -1
- package/dist/Effectable.d.ts.map +1 -1
- package/dist/Effectable.js +3 -1
- package/dist/Effectable.js.map +1 -1
- package/dist/Encoding.d.ts +16 -0
- package/dist/Encoding.d.ts.map +1 -1
- package/dist/Encoding.js +16 -0
- package/dist/Encoding.js.map +1 -1
- package/dist/Equal.d.ts +52 -40
- package/dist/Equal.d.ts.map +1 -1
- package/dist/Equal.js +32 -26
- package/dist/Equal.js.map +1 -1
- package/dist/Equivalence.d.ts +190 -153
- package/dist/Equivalence.d.ts.map +1 -1
- package/dist/Equivalence.js +129 -104
- package/dist/Equivalence.js.map +1 -1
- package/dist/ErrorReporter.d.ts +35 -14
- package/dist/ErrorReporter.d.ts.map +1 -1
- package/dist/ErrorReporter.js +18 -6
- package/dist/ErrorReporter.js.map +1 -1
- package/dist/ExecutionPlan.d.ts +10 -3
- package/dist/ExecutionPlan.d.ts.map +1 -1
- package/dist/ExecutionPlan.js +4 -3
- package/dist/ExecutionPlan.js.map +1 -1
- package/dist/Exit.d.ts +212 -6
- package/dist/Exit.d.ts.map +1 -1
- package/dist/Exit.js +139 -2
- package/dist/Exit.js.map +1 -1
- package/dist/Fiber.d.ts +8 -0
- package/dist/Fiber.d.ts.map +1 -1
- package/dist/Fiber.js +4 -0
- package/dist/Fiber.js.map +1 -1
- package/dist/FiberHandle.d.ts +46 -23
- package/dist/FiberHandle.d.ts.map +1 -1
- package/dist/FiberHandle.js +27 -11
- package/dist/FiberHandle.js.map +1 -1
- package/dist/FiberMap.d.ts +43 -4
- package/dist/FiberMap.d.ts.map +1 -1
- package/dist/FiberMap.js +27 -4
- package/dist/FiberMap.js.map +1 -1
- package/dist/FiberSet.d.ts +21 -6
- package/dist/FiberSet.d.ts.map +1 -1
- package/dist/FiberSet.js +17 -6
- package/dist/FiberSet.js.map +1 -1
- package/dist/FileSystem.d.ts +64 -0
- package/dist/FileSystem.d.ts.map +1 -1
- package/dist/FileSystem.js +26 -0
- package/dist/FileSystem.js.map +1 -1
- package/dist/Filter.d.ts +53 -21
- package/dist/Filter.d.ts.map +1 -1
- package/dist/Filter.js +20 -9
- package/dist/Filter.js.map +1 -1
- package/dist/Formatter.d.ts +21 -22
- package/dist/Formatter.d.ts.map +1 -1
- package/dist/Formatter.js +12 -12
- package/dist/Formatter.js.map +1 -1
- package/dist/Function.d.ts +67 -75
- package/dist/Function.d.ts.map +1 -1
- package/dist/Function.js +29 -19
- package/dist/Function.js.map +1 -1
- package/dist/Graph.d.ts +51 -13
- package/dist/Graph.d.ts.map +1 -1
- package/dist/Graph.js +19 -3
- package/dist/Graph.js.map +1 -1
- package/dist/HKT.d.ts +22 -21
- package/dist/HKT.d.ts.map +1 -1
- package/dist/Hash.d.ts +33 -10
- package/dist/Hash.d.ts.map +1 -1
- package/dist/Hash.js +27 -10
- package/dist/Hash.js.map +1 -1
- package/dist/HashMap.d.ts +50 -9
- package/dist/HashMap.d.ts.map +1 -1
- package/dist/HashMap.js +17 -3
- package/dist/HashMap.js.map +1 -1
- package/dist/HashRing.d.ts +4 -0
- package/dist/HashRing.d.ts.map +1 -1
- package/dist/HashRing.js +2 -0
- package/dist/HashRing.js.map +1 -1
- package/dist/HashSet.d.ts +2 -0
- package/dist/HashSet.d.ts.map +1 -1
- package/dist/HashSet.js.map +1 -1
- package/dist/Inspectable.d.ts +15 -2
- package/dist/Inspectable.d.ts.map +1 -1
- package/dist/Inspectable.js +11 -2
- package/dist/Inspectable.js.map +1 -1
- package/dist/Iterable.d.ts +104 -22
- package/dist/Iterable.d.ts.map +1 -1
- package/dist/Iterable.js +46 -12
- package/dist/Iterable.js.map +1 -1
- package/dist/JsonPatch.d.ts +61 -80
- package/dist/JsonPatch.d.ts.map +1 -1
- package/dist/JsonPatch.js +35 -42
- package/dist/JsonPatch.js.map +1 -1
- package/dist/JsonPointer.d.ts +16 -20
- package/dist/JsonPointer.d.ts.map +1 -1
- package/dist/JsonPointer.js +16 -20
- package/dist/JsonPointer.js.map +1 -1
- package/dist/JsonSchema.d.ts +123 -73
- package/dist/JsonSchema.d.ts.map +1 -1
- package/dist/JsonSchema.js +95 -53
- package/dist/JsonSchema.js.map +1 -1
- package/dist/Latch.d.ts +28 -2
- package/dist/Latch.d.ts.map +1 -1
- package/dist/Latch.js +22 -2
- package/dist/Latch.js.map +1 -1
- package/dist/Layer.d.ts +781 -335
- package/dist/Layer.d.ts.map +1 -1
- package/dist/Layer.js +324 -129
- package/dist/Layer.js.map +1 -1
- package/dist/LogLevel.d.ts +86 -13
- package/dist/LogLevel.d.ts.map +1 -1
- package/dist/LogLevel.js +30 -4
- package/dist/LogLevel.js.map +1 -1
- package/dist/Logger.d.ts +63 -51
- package/dist/Logger.d.ts.map +1 -1
- package/dist/Logger.js +61 -51
- package/dist/Logger.js.map +1 -1
- package/dist/ManagedRuntime.d.ts +12 -0
- package/dist/ManagedRuntime.d.ts.map +1 -1
- package/dist/ManagedRuntime.js +1 -0
- package/dist/ManagedRuntime.js.map +1 -1
- package/dist/Match.d.ts +83 -1
- package/dist/Match.d.ts.map +1 -1
- package/dist/Match.js +31 -1
- package/dist/Match.js.map +1 -1
- package/dist/Metric.d.ts +89 -12
- package/dist/Metric.d.ts.map +1 -1
- package/dist/Metric.js +53 -8
- package/dist/Metric.js.map +1 -1
- package/dist/MutableHashMap.d.ts +14 -0
- package/dist/MutableHashMap.d.ts.map +1 -1
- package/dist/MutableHashMap.js +4 -0
- package/dist/MutableHashMap.js.map +1 -1
- package/dist/MutableHashSet.d.ts +2 -0
- package/dist/MutableHashSet.d.ts.map +1 -1
- package/dist/MutableHashSet.js.map +1 -1
- package/dist/MutableList.d.ts +24 -6
- package/dist/MutableList.d.ts.map +1 -1
- package/dist/MutableList.js +22 -6
- package/dist/MutableList.js.map +1 -1
- package/dist/MutableRef.d.ts +2 -0
- package/dist/MutableRef.d.ts.map +1 -1
- package/dist/MutableRef.js.map +1 -1
- package/dist/Newtype.d.ts +69 -30
- package/dist/Newtype.d.ts.map +1 -1
- package/dist/Newtype.js +52 -22
- package/dist/Newtype.js.map +1 -1
- package/dist/NonEmptyIterable.d.ts +6 -0
- package/dist/NonEmptyIterable.d.ts.map +1 -1
- package/dist/NonEmptyIterable.js +2 -0
- package/dist/NonEmptyIterable.js.map +1 -1
- package/dist/Number.d.ts +16 -30
- package/dist/Number.d.ts.map +1 -1
- package/dist/Number.js +6 -12
- package/dist/Number.js.map +1 -1
- package/dist/Optic.d.ts +90 -40
- package/dist/Optic.d.ts.map +1 -1
- package/dist/Optic.js +48 -24
- package/dist/Optic.js.map +1 -1
- package/dist/Option.d.ts +121 -111
- package/dist/Option.d.ts.map +1 -1
- package/dist/Option.js +56 -54
- package/dist/Option.js.map +1 -1
- package/dist/Order.d.ts +169 -167
- package/dist/Order.d.ts.map +1 -1
- package/dist/Order.js +135 -135
- package/dist/Order.js.map +1 -1
- package/dist/Ordering.d.ts +4 -0
- package/dist/Ordering.d.ts.map +1 -1
- package/dist/Ordering.js +2 -0
- package/dist/Ordering.js.map +1 -1
- package/dist/PartitionedSemaphore.d.ts +7 -5
- package/dist/PartitionedSemaphore.d.ts.map +1 -1
- package/dist/PartitionedSemaphore.js +5 -5
- package/dist/PartitionedSemaphore.js.map +1 -1
- package/dist/Path.d.ts +8 -0
- package/dist/Path.d.ts.map +1 -1
- package/dist/Path.js +4 -0
- package/dist/Path.js.map +1 -1
- package/dist/Pipeable.d.ts +10 -0
- package/dist/Pipeable.d.ts.map +1 -1
- package/dist/Pipeable.js +8 -0
- package/dist/Pipeable.js.map +1 -1
- package/dist/PlatformError.d.ts +12 -0
- package/dist/PlatformError.d.ts.map +1 -1
- package/dist/PlatformError.js +10 -0
- package/dist/PlatformError.js.map +1 -1
- package/dist/Pool.d.ts +30 -16
- package/dist/Pool.d.ts.map +1 -1
- package/dist/Pool.js +30 -16
- package/dist/Pool.js.map +1 -1
- package/dist/Predicate.d.ts +520 -352
- package/dist/Predicate.d.ts.map +1 -1
- package/dist/Predicate.js +271 -184
- package/dist/Predicate.js.map +1 -1
- package/dist/PrimaryKey.d.ts +4 -0
- package/dist/PrimaryKey.d.ts.map +1 -1
- package/dist/PrimaryKey.js +2 -0
- package/dist/PrimaryKey.js.map +1 -1
- package/dist/PubSub.d.ts +22 -4
- package/dist/PubSub.d.ts.map +1 -1
- package/dist/PubSub.js +17 -3
- package/dist/PubSub.js.map +1 -1
- package/dist/Pull.d.ts +16 -0
- package/dist/Pull.d.ts.map +1 -1
- package/dist/Pull.js +10 -0
- package/dist/Pull.js.map +1 -1
- package/dist/Queue.d.ts +44 -0
- package/dist/Queue.d.ts.map +1 -1
- package/dist/Queue.js +28 -0
- package/dist/Queue.js.map +1 -1
- package/dist/Random.d.ts +25 -6
- package/dist/Random.d.ts.map +1 -1
- package/dist/Random.js +11 -2
- package/dist/Random.js.map +1 -1
- package/dist/RcMap.d.ts +10 -6
- package/dist/RcMap.d.ts.map +1 -1
- package/dist/RcMap.js +2 -2
- package/dist/RcMap.js.map +1 -1
- package/dist/RcRef.d.ts +3 -1
- package/dist/RcRef.d.ts.map +1 -1
- package/dist/RcRef.js.map +1 -1
- package/dist/Record.d.ts +24 -3
- package/dist/Record.d.ts.map +1 -1
- package/dist/Record.js +12 -3
- package/dist/Record.js.map +1 -1
- package/dist/Redactable.d.ts +54 -41
- package/dist/Redactable.d.ts.map +1 -1
- package/dist/Redactable.js +42 -32
- package/dist/Redactable.js.map +1 -1
- package/dist/Redacted.d.ts +10 -0
- package/dist/Redacted.d.ts.map +1 -1
- package/dist/Redacted.js +6 -0
- package/dist/Redacted.js.map +1 -1
- package/dist/Reducer.d.ts +20 -11
- package/dist/Reducer.d.ts.map +1 -1
- package/dist/Reducer.js +10 -6
- package/dist/Reducer.js.map +1 -1
- package/dist/Ref.d.ts +45 -24
- package/dist/Ref.d.ts.map +1 -1
- package/dist/Ref.js +41 -21
- package/dist/Ref.js.map +1 -1
- package/dist/References.d.ts +18 -1
- package/dist/References.d.ts.map +1 -1
- package/dist/References.js +17 -1
- package/dist/References.js.map +1 -1
- package/dist/Request.d.ts +3 -3
- package/dist/Request.js +2 -2
- package/dist/RequestResolver.d.ts +7 -17
- package/dist/RequestResolver.d.ts.map +1 -1
- package/dist/RequestResolver.js +3 -5
- package/dist/RequestResolver.js.map +1 -1
- package/dist/Resource.d.ts +2 -0
- package/dist/Resource.d.ts.map +1 -1
- package/dist/Resource.js +2 -0
- package/dist/Resource.js.map +1 -1
- package/dist/Result.d.ts +188 -6
- package/dist/Result.d.ts.map +1 -1
- package/dist/Result.js +84 -2
- package/dist/Result.js.map +1 -1
- package/dist/Runtime.d.ts +14 -11
- package/dist/Runtime.d.ts.map +1 -1
- package/dist/Runtime.js +11 -9
- package/dist/Runtime.js.map +1 -1
- package/dist/Schedule.d.ts +27 -3
- package/dist/Schedule.d.ts.map +1 -1
- package/dist/Schedule.js +21 -2
- package/dist/Schedule.js.map +1 -1
- package/dist/Scheduler.d.ts +22 -19
- package/dist/Scheduler.d.ts.map +1 -1
- package/dist/Scheduler.js +14 -12
- package/dist/Scheduler.js.map +1 -1
- package/dist/Schema.d.ts +547 -130
- package/dist/Schema.d.ts.map +1 -1
- package/dist/Schema.js +409 -121
- package/dist/Schema.js.map +1 -1
- package/dist/SchemaAST.d.ts +123 -65
- package/dist/SchemaAST.d.ts.map +1 -1
- package/dist/SchemaAST.js +90 -39
- package/dist/SchemaAST.js.map +1 -1
- package/dist/SchemaGetter.d.ts +269 -234
- package/dist/SchemaGetter.d.ts.map +1 -1
- package/dist/SchemaGetter.js +245 -215
- package/dist/SchemaGetter.js.map +1 -1
- package/dist/SchemaIssue.d.ts +48 -46
- package/dist/SchemaIssue.d.ts.map +1 -1
- package/dist/SchemaIssue.js +34 -34
- package/dist/SchemaIssue.js.map +1 -1
- package/dist/SchemaParser.d.ts +58 -0
- package/dist/SchemaParser.d.ts.map +1 -1
- package/dist/SchemaParser.js +58 -0
- package/dist/SchemaParser.js.map +1 -1
- package/dist/SchemaRepresentation.d.ts +198 -96
- package/dist/SchemaRepresentation.d.ts.map +1 -1
- package/dist/SchemaRepresentation.js +107 -45
- package/dist/SchemaRepresentation.js.map +1 -1
- package/dist/SchemaTransformation.d.ts +272 -203
- package/dist/SchemaTransformation.d.ts.map +1 -1
- package/dist/SchemaTransformation.js +249 -187
- package/dist/SchemaTransformation.js.map +1 -1
- package/dist/SchemaUtils.d.ts +2 -0
- package/dist/SchemaUtils.d.ts.map +1 -1
- package/dist/SchemaUtils.js +2 -0
- package/dist/SchemaUtils.js.map +1 -1
- package/dist/Scope.d.ts +18 -0
- package/dist/Scope.d.ts.map +1 -1
- package/dist/Scope.js +12 -0
- package/dist/Scope.js.map +1 -1
- package/dist/ScopedCache.d.ts +44 -0
- package/dist/ScopedCache.d.ts.map +1 -1
- package/dist/ScopedCache.js +18 -0
- package/dist/ScopedCache.js.map +1 -1
- package/dist/ScopedRef.d.ts +9 -3
- package/dist/ScopedRef.d.ts.map +1 -1
- package/dist/ScopedRef.js +3 -1
- package/dist/ScopedRef.js.map +1 -1
- package/dist/Semaphore.d.ts +6 -0
- package/dist/Semaphore.d.ts.map +1 -1
- package/dist/Semaphore.js +4 -0
- package/dist/Semaphore.js.map +1 -1
- package/dist/Sink.d.ts +108 -0
- package/dist/Sink.d.ts.map +1 -1
- package/dist/Sink.js +54 -0
- package/dist/Sink.js.map +1 -1
- package/dist/Stdio.d.ts +7 -3
- package/dist/Stdio.d.ts.map +1 -1
- package/dist/Stdio.js +2 -0
- package/dist/Stdio.js.map +1 -1
- package/dist/Stream.d.ts +416 -16
- package/dist/Stream.d.ts.map +1 -1
- package/dist/Stream.js +164 -8
- package/dist/Stream.js.map +1 -1
- package/dist/String.d.ts +14 -0
- package/dist/String.d.ts.map +1 -1
- package/dist/String.js +6 -0
- package/dist/String.js.map +1 -1
- package/dist/Struct.d.ts +371 -191
- package/dist/Struct.d.ts.map +1 -1
- package/dist/Struct.js +144 -77
- package/dist/Struct.js.map +1 -1
- package/dist/SubscriptionRef.d.ts +7 -1
- package/dist/SubscriptionRef.d.ts.map +1 -1
- package/dist/SubscriptionRef.js +5 -1
- package/dist/SubscriptionRef.js.map +1 -1
- package/dist/SynchronizedRef.d.ts +2 -0
- package/dist/SynchronizedRef.d.ts.map +1 -1
- package/dist/SynchronizedRef.js +2 -0
- package/dist/SynchronizedRef.js.map +1 -1
- package/dist/Tracer.d.ts +17 -27
- package/dist/Tracer.d.ts.map +1 -1
- package/dist/Tracer.js +8 -12
- package/dist/Tracer.js.map +1 -1
- package/dist/Trie.d.ts +23 -9
- package/dist/Trie.d.ts.map +1 -1
- package/dist/Trie.js +13 -3
- package/dist/Trie.js.map +1 -1
- package/dist/Tuple.d.ts +287 -144
- package/dist/Tuple.d.ts.map +1 -1
- package/dist/Tuple.js +135 -66
- package/dist/Tuple.js.map +1 -1
- package/dist/TxChunk.d.ts +182 -93
- package/dist/TxChunk.d.ts.map +1 -1
- package/dist/TxChunk.js +68 -35
- package/dist/TxChunk.js.map +1 -1
- package/dist/TxDeferred.d.ts +3 -4
- package/dist/TxDeferred.d.ts.map +1 -1
- package/dist/TxDeferred.js.map +1 -1
- package/dist/TxHashMap.d.ts +163 -86
- package/dist/TxHashMap.d.ts.map +1 -1
- package/dist/TxHashMap.js +57 -30
- package/dist/TxHashMap.js.map +1 -1
- package/dist/TxHashSet.d.ts +24 -27
- package/dist/TxHashSet.d.ts.map +1 -1
- package/dist/TxHashSet.js +9 -6
- package/dist/TxHashSet.js.map +1 -1
- package/dist/TxPriorityQueue.d.ts +2 -0
- package/dist/TxPriorityQueue.d.ts.map +1 -1
- package/dist/TxPriorityQueue.js.map +1 -1
- package/dist/TxPubSub.d.ts +36 -35
- package/dist/TxPubSub.d.ts.map +1 -1
- package/dist/TxPubSub.js +22 -21
- package/dist/TxPubSub.js.map +1 -1
- package/dist/TxQueue.d.ts +77 -114
- package/dist/TxQueue.d.ts.map +1 -1
- package/dist/TxQueue.js +45 -62
- package/dist/TxQueue.js.map +1 -1
- package/dist/TxRef.d.ts +4 -0
- package/dist/TxRef.d.ts.map +1 -1
- package/dist/TxRef.js +2 -0
- package/dist/TxRef.js.map +1 -1
- package/dist/TxSemaphore.d.ts +66 -27
- package/dist/TxSemaphore.d.ts.map +1 -1
- package/dist/TxSemaphore.js +38 -15
- package/dist/TxSemaphore.js.map +1 -1
- package/dist/Types.d.ts +202 -75
- package/dist/Types.d.ts.map +1 -1
- package/dist/UndefinedOr.d.ts +31 -29
- package/dist/UndefinedOr.d.ts.map +1 -1
- package/dist/UndefinedOr.js +27 -21
- package/dist/UndefinedOr.js.map +1 -1
- package/dist/Unify.d.ts +28 -0
- package/dist/Unify.d.ts.map +1 -1
- package/dist/Unify.js +2 -0
- package/dist/Unify.js.map +1 -1
- package/dist/Utils.d.ts +29 -35
- package/dist/Utils.d.ts.map +1 -1
- package/dist/Utils.js +11 -13
- package/dist/Utils.js.map +1 -1
- package/dist/index.d.ts +18 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +18 -7
- package/dist/index.js.map +1 -1
- package/dist/testing/TestClock.d.ts +17 -17
- package/dist/testing/TestClock.js +1 -1
- package/dist/testing/TestClock.js.map +1 -1
- package/dist/testing/TestConsole.d.ts +2 -0
- package/dist/testing/TestConsole.d.ts.map +1 -1
- package/dist/testing/TestConsole.js.map +1 -1
- package/dist/testing/TestSchema.d.ts +43 -55
- package/dist/testing/TestSchema.d.ts.map +1 -1
- package/dist/testing/TestSchema.js +43 -55
- package/dist/testing/TestSchema.js.map +1 -1
- package/dist/unstable/ai/AiError.d.ts +62 -11
- package/dist/unstable/ai/AiError.d.ts.map +1 -1
- package/dist/unstable/ai/AiError.js +58 -11
- package/dist/unstable/ai/AiError.js.map +1 -1
- package/dist/unstable/ai/AnthropicStructuredOutput.d.ts +4 -4
- package/dist/unstable/ai/AnthropicStructuredOutput.js +4 -4
- package/dist/unstable/ai/Chat.d.ts +29 -1
- package/dist/unstable/ai/Chat.d.ts.map +1 -1
- package/dist/unstable/ai/Chat.js +15 -1
- package/dist/unstable/ai/Chat.js.map +1 -1
- package/dist/unstable/ai/IdGenerator.d.ts +10 -0
- package/dist/unstable/ai/IdGenerator.d.ts.map +1 -1
- package/dist/unstable/ai/IdGenerator.js +8 -0
- package/dist/unstable/ai/IdGenerator.js.map +1 -1
- package/dist/unstable/ai/LanguageModel.d.ts +32 -46
- package/dist/unstable/ai/LanguageModel.d.ts.map +1 -1
- package/dist/unstable/ai/LanguageModel.js +5 -14
- package/dist/unstable/ai/LanguageModel.js.map +1 -1
- package/dist/unstable/ai/McpSchema.d.ts +84 -32
- package/dist/unstable/ai/McpSchema.d.ts.map +1 -1
- package/dist/unstable/ai/McpSchema.js +73 -28
- package/dist/unstable/ai/McpSchema.js.map +1 -1
- package/dist/unstable/ai/McpServer.d.ts +8 -0
- package/dist/unstable/ai/McpServer.d.ts.map +1 -1
- package/dist/unstable/ai/McpServer.js +6 -0
- package/dist/unstable/ai/McpServer.js.map +1 -1
- package/dist/unstable/ai/Model.d.ts +9 -5
- package/dist/unstable/ai/Model.d.ts.map +1 -1
- package/dist/unstable/ai/Model.js +4 -0
- package/dist/unstable/ai/Model.js.map +1 -1
- package/dist/unstable/ai/OpenAiStructuredOutput.d.ts +3 -2
- package/dist/unstable/ai/OpenAiStructuredOutput.d.ts.map +1 -1
- package/dist/unstable/ai/OpenAiStructuredOutput.js +3 -2
- package/dist/unstable/ai/OpenAiStructuredOutput.js.map +1 -1
- package/dist/unstable/ai/Prompt.d.ts +62 -35
- package/dist/unstable/ai/Prompt.d.ts.map +1 -1
- package/dist/unstable/ai/Prompt.js +16 -15
- package/dist/unstable/ai/Prompt.js.map +1 -1
- package/dist/unstable/ai/Response.d.ts +40 -21
- package/dist/unstable/ai/Response.d.ts.map +1 -1
- package/dist/unstable/ai/Response.js +10 -0
- package/dist/unstable/ai/Response.js.map +1 -1
- package/dist/unstable/ai/ResponseIdTracker.d.ts +8 -0
- package/dist/unstable/ai/ResponseIdTracker.d.ts.map +1 -1
- package/dist/unstable/ai/ResponseIdTracker.js +4 -0
- package/dist/unstable/ai/ResponseIdTracker.js.map +1 -1
- package/dist/unstable/ai/Telemetry.d.ts +30 -5
- package/dist/unstable/ai/Telemetry.d.ts.map +1 -1
- package/dist/unstable/ai/Telemetry.js +7 -1
- package/dist/unstable/ai/Telemetry.js.map +1 -1
- package/dist/unstable/ai/Tokenizer.d.ts +6 -0
- package/dist/unstable/ai/Tokenizer.d.ts.map +1 -1
- package/dist/unstable/ai/Tokenizer.js +4 -0
- package/dist/unstable/ai/Tokenizer.js.map +1 -1
- package/dist/unstable/ai/Tool.d.ts +68 -0
- package/dist/unstable/ai/Tool.d.ts.map +1 -1
- package/dist/unstable/ai/Tool.js +36 -0
- package/dist/unstable/ai/Tool.js.map +1 -1
- package/dist/unstable/ai/Toolkit.d.ts +12 -0
- package/dist/unstable/ai/Toolkit.d.ts.map +1 -1
- package/dist/unstable/ai/Toolkit.js +6 -0
- package/dist/unstable/ai/Toolkit.js.map +1 -1
- package/dist/unstable/cli/Argument.d.ts +14 -4
- package/dist/unstable/cli/Argument.d.ts.map +1 -1
- package/dist/unstable/cli/Argument.js +4 -0
- package/dist/unstable/cli/Argument.js.map +1 -1
- package/dist/unstable/cli/CliError.d.ts +6 -0
- package/dist/unstable/cli/CliError.d.ts.map +1 -1
- package/dist/unstable/cli/CliError.js +4 -0
- package/dist/unstable/cli/CliError.js.map +1 -1
- package/dist/unstable/cli/Command.d.ts +123 -12
- package/dist/unstable/cli/Command.d.ts.map +1 -1
- package/dist/unstable/cli/Command.js +57 -4
- package/dist/unstable/cli/Command.js.map +1 -1
- package/dist/unstable/cli/Flag.d.ts +31 -14
- package/dist/unstable/cli/Flag.d.ts.map +1 -1
- package/dist/unstable/cli/Flag.js +23 -10
- package/dist/unstable/cli/Flag.js.map +1 -1
- package/dist/unstable/cli/Param.d.ts +10 -0
- package/dist/unstable/cli/Param.d.ts.map +1 -1
- package/dist/unstable/cli/Param.js +46 -5
- package/dist/unstable/cli/Param.js.map +1 -1
- package/dist/unstable/cli/Primitive.d.ts +10 -0
- package/dist/unstable/cli/Primitive.d.ts.map +1 -1
- package/dist/unstable/cli/Primitive.js +10 -0
- package/dist/unstable/cli/Primitive.js.map +1 -1
- package/dist/unstable/cli/Prompt.d.ts +47 -40
- package/dist/unstable/cli/Prompt.d.ts.map +1 -1
- package/dist/unstable/cli/Prompt.js +25 -20
- package/dist/unstable/cli/Prompt.js.map +1 -1
- package/dist/unstable/cli/internal/command.d.ts +1 -0
- package/dist/unstable/cli/internal/command.d.ts.map +1 -1
- package/dist/unstable/cli/internal/command.js +10 -2
- package/dist/unstable/cli/internal/command.js.map +1 -1
- package/dist/unstable/cli/internal/completions/descriptor.js +3 -0
- package/dist/unstable/cli/internal/completions/descriptor.js.map +1 -1
- package/dist/unstable/cli/internal/parser.js +8 -1
- package/dist/unstable/cli/internal/parser.js.map +1 -1
- package/dist/unstable/cluster/ClusterCron.d.ts +10 -1
- package/dist/unstable/cluster/ClusterCron.d.ts.map +1 -1
- package/dist/unstable/cluster/ClusterCron.js +2 -0
- package/dist/unstable/cluster/ClusterCron.js.map +1 -1
- package/dist/unstable/cluster/ClusterSchema.d.ts +8 -0
- package/dist/unstable/cluster/ClusterSchema.d.ts.map +1 -1
- package/dist/unstable/cluster/ClusterSchema.js +8 -0
- package/dist/unstable/cluster/ClusterSchema.js.map +1 -1
- package/dist/unstable/cluster/ClusterWorkflowEngine.d.ts +4 -0
- package/dist/unstable/cluster/ClusterWorkflowEngine.d.ts.map +1 -1
- package/dist/unstable/cluster/ClusterWorkflowEngine.js +4 -0
- package/dist/unstable/cluster/ClusterWorkflowEngine.js.map +1 -1
- package/dist/unstable/cluster/DeliverAt.d.ts +3 -4
- package/dist/unstable/cluster/DeliverAt.d.ts.map +1 -1
- package/dist/unstable/cluster/DeliverAt.js.map +1 -1
- package/dist/unstable/cluster/Entity.d.ts +24 -0
- package/dist/unstable/cluster/Entity.d.ts.map +1 -1
- package/dist/unstable/cluster/Entity.js +12 -0
- package/dist/unstable/cluster/Entity.js.map +1 -1
- package/dist/unstable/cluster/EntityProxy.d.ts +10 -4
- package/dist/unstable/cluster/EntityProxy.d.ts.map +1 -1
- package/dist/unstable/cluster/EntityProxy.js.map +1 -1
- package/dist/unstable/cluster/EntityProxyServer.d.ts +6 -0
- package/dist/unstable/cluster/EntityProxyServer.d.ts.map +1 -1
- package/dist/unstable/cluster/EntityProxyServer.js +4 -0
- package/dist/unstable/cluster/EntityProxyServer.js.map +1 -1
- package/dist/unstable/cluster/EntityResource.d.ts +10 -0
- package/dist/unstable/cluster/EntityResource.d.ts.map +1 -1
- package/dist/unstable/cluster/EntityResource.js +8 -0
- package/dist/unstable/cluster/EntityResource.js.map +1 -1
- package/dist/unstable/cluster/Envelope.d.ts +16 -0
- package/dist/unstable/cluster/Envelope.d.ts.map +1 -1
- package/dist/unstable/cluster/Envelope.js +10 -0
- package/dist/unstable/cluster/Envelope.js.map +1 -1
- package/dist/unstable/cluster/HttpRunner.d.ts +16 -0
- package/dist/unstable/cluster/HttpRunner.d.ts.map +1 -1
- package/dist/unstable/cluster/HttpRunner.js +16 -0
- package/dist/unstable/cluster/HttpRunner.js.map +1 -1
- package/dist/unstable/cluster/K8sHttpClient.d.ts +8 -0
- package/dist/unstable/cluster/K8sHttpClient.d.ts.map +1 -1
- package/dist/unstable/cluster/K8sHttpClient.js +8 -0
- package/dist/unstable/cluster/K8sHttpClient.js.map +1 -1
- package/dist/unstable/cluster/Message.d.ts +24 -0
- package/dist/unstable/cluster/Message.d.ts.map +1 -1
- package/dist/unstable/cluster/Message.js +18 -0
- package/dist/unstable/cluster/Message.js.map +1 -1
- package/dist/unstable/cluster/MessageStorage.d.ts +64 -20
- package/dist/unstable/cluster/MessageStorage.d.ts.map +1 -1
- package/dist/unstable/cluster/MessageStorage.js +8 -0
- package/dist/unstable/cluster/MessageStorage.js.map +1 -1
- package/dist/unstable/cluster/Reply.d.ts +6 -6
- package/dist/unstable/cluster/Reply.d.ts.map +1 -1
- package/dist/unstable/cluster/Reply.js +4 -3
- package/dist/unstable/cluster/Reply.js.map +1 -1
- package/dist/unstable/cluster/Runner.d.ts +2 -0
- package/dist/unstable/cluster/Runner.d.ts.map +1 -1
- package/dist/unstable/cluster/Runner.js +2 -0
- package/dist/unstable/cluster/Runner.js.map +1 -1
- package/dist/unstable/cluster/RunnerHealth.d.ts +13 -2
- package/dist/unstable/cluster/RunnerHealth.d.ts.map +1 -1
- package/dist/unstable/cluster/RunnerHealth.js +13 -2
- package/dist/unstable/cluster/RunnerHealth.js.map +1 -1
- package/dist/unstable/cluster/RunnerServer.d.ts +8 -8
- package/dist/unstable/cluster/RunnerServer.d.ts.map +1 -1
- package/dist/unstable/cluster/RunnerServer.js +8 -8
- package/dist/unstable/cluster/RunnerServer.js.map +1 -1
- package/dist/unstable/cluster/RunnerStorage.d.ts +2 -0
- package/dist/unstable/cluster/RunnerStorage.d.ts.map +1 -1
- package/dist/unstable/cluster/RunnerStorage.js +2 -0
- package/dist/unstable/cluster/RunnerStorage.js.map +1 -1
- package/dist/unstable/cluster/ShardId.d.ts +4 -0
- package/dist/unstable/cluster/ShardId.d.ts.map +1 -1
- package/dist/unstable/cluster/ShardId.js +4 -0
- package/dist/unstable/cluster/ShardId.js.map +1 -1
- package/dist/unstable/cluster/Snowflake.d.ts +2 -0
- package/dist/unstable/cluster/Snowflake.d.ts.map +1 -1
- package/dist/unstable/cluster/Snowflake.js +2 -0
- package/dist/unstable/cluster/Snowflake.js.map +1 -1
- package/dist/unstable/cluster/TestRunner.d.ts +3 -2
- package/dist/unstable/cluster/TestRunner.d.ts.map +1 -1
- package/dist/unstable/cluster/TestRunner.js +3 -2
- package/dist/unstable/cluster/TestRunner.js.map +1 -1
- package/dist/unstable/devtools/DevToolsSchema.d.ts +34 -2
- package/dist/unstable/devtools/DevToolsSchema.d.ts.map +1 -1
- package/dist/unstable/devtools/DevToolsSchema.js +14 -0
- package/dist/unstable/devtools/DevToolsSchema.js.map +1 -1
- package/dist/unstable/devtools/DevToolsServer.d.ts +4 -0
- package/dist/unstable/devtools/DevToolsServer.d.ts.map +1 -1
- package/dist/unstable/devtools/DevToolsServer.js +2 -0
- package/dist/unstable/devtools/DevToolsServer.js.map +1 -1
- package/dist/unstable/encoding/Msgpack.d.ts +24 -0
- package/dist/unstable/encoding/Msgpack.d.ts.map +1 -1
- package/dist/unstable/encoding/Msgpack.js +18 -0
- package/dist/unstable/encoding/Msgpack.js.map +1 -1
- package/dist/unstable/encoding/Ndjson.d.ts +46 -2
- package/dist/unstable/encoding/Ndjson.d.ts.map +1 -1
- package/dist/unstable/encoding/Ndjson.js +30 -2
- package/dist/unstable/encoding/Ndjson.js.map +1 -1
- package/dist/unstable/encoding/Sse.d.ts +24 -17
- package/dist/unstable/encoding/Sse.d.ts.map +1 -1
- package/dist/unstable/encoding/Sse.js +20 -11
- package/dist/unstable/encoding/Sse.js.map +1 -1
- package/dist/unstable/eventlog/Event.d.ts +16 -0
- package/dist/unstable/eventlog/Event.d.ts.map +1 -1
- package/dist/unstable/eventlog/Event.js.map +1 -1
- package/dist/unstable/eventlog/EventGroup.d.ts +4 -0
- package/dist/unstable/eventlog/EventGroup.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventGroup.js +2 -0
- package/dist/unstable/eventlog/EventGroup.js.map +1 -1
- package/dist/unstable/eventlog/EventJournal.d.ts +20 -0
- package/dist/unstable/eventlog/EventJournal.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventJournal.js +18 -0
- package/dist/unstable/eventlog/EventJournal.js.map +1 -1
- package/dist/unstable/eventlog/EventLog.d.ts +22 -0
- package/dist/unstable/eventlog/EventLog.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLog.js +18 -0
- package/dist/unstable/eventlog/EventLog.js.map +1 -1
- package/dist/unstable/eventlog/EventLogMessage.d.ts +10 -0
- package/dist/unstable/eventlog/EventLogMessage.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogMessage.js +10 -0
- package/dist/unstable/eventlog/EventLogMessage.js.map +1 -1
- package/dist/unstable/eventlog/EventLogRemote.d.ts +4 -0
- package/dist/unstable/eventlog/EventLogRemote.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogRemote.js +4 -0
- package/dist/unstable/eventlog/EventLogRemote.js.map +1 -1
- package/dist/unstable/eventlog/EventLogServer.d.ts +4 -0
- package/dist/unstable/eventlog/EventLogServer.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogServer.js +4 -0
- package/dist/unstable/eventlog/EventLogServer.js.map +1 -1
- package/dist/unstable/eventlog/EventLogServerEncrypted.d.ts +6 -0
- package/dist/unstable/eventlog/EventLogServerEncrypted.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogServerEncrypted.js +6 -0
- package/dist/unstable/eventlog/EventLogServerEncrypted.js.map +1 -1
- package/dist/unstable/eventlog/EventLogServerUnencrypted.d.ts +8 -0
- package/dist/unstable/eventlog/EventLogServerUnencrypted.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogServerUnencrypted.js +8 -0
- package/dist/unstable/eventlog/EventLogServerUnencrypted.js.map +1 -1
- package/dist/unstable/eventlog/EventLogSessionAuth.d.ts +11 -1
- package/dist/unstable/eventlog/EventLogSessionAuth.d.ts.map +1 -1
- package/dist/unstable/eventlog/EventLogSessionAuth.js +11 -1
- package/dist/unstable/eventlog/EventLogSessionAuth.js.map +1 -1
- package/dist/unstable/eventlog/SqlEventJournal.d.ts +2 -0
- package/dist/unstable/eventlog/SqlEventJournal.d.ts.map +1 -1
- package/dist/unstable/eventlog/SqlEventJournal.js +2 -0
- package/dist/unstable/eventlog/SqlEventJournal.js.map +1 -1
- package/dist/unstable/eventlog/SqlEventLogServerEncrypted.d.ts +2 -0
- package/dist/unstable/eventlog/SqlEventLogServerEncrypted.d.ts.map +1 -1
- package/dist/unstable/eventlog/SqlEventLogServerEncrypted.js +2 -0
- package/dist/unstable/eventlog/SqlEventLogServerEncrypted.js.map +1 -1
- package/dist/unstable/eventlog/SqlEventLogServerUnencrypted.d.ts +2 -0
- package/dist/unstable/eventlog/SqlEventLogServerUnencrypted.d.ts.map +1 -1
- package/dist/unstable/eventlog/SqlEventLogServerUnencrypted.js +2 -0
- package/dist/unstable/eventlog/SqlEventLogServerUnencrypted.js.map +1 -1
- package/dist/unstable/http/Cookies.d.ts +34 -0
- package/dist/unstable/http/Cookies.d.ts.map +1 -1
- package/dist/unstable/http/Cookies.js +18 -0
- package/dist/unstable/http/Cookies.js.map +1 -1
- package/dist/unstable/http/Etag.d.ts +4 -0
- package/dist/unstable/http/Etag.d.ts.map +1 -1
- package/dist/unstable/http/Etag.js.map +1 -1
- package/dist/unstable/http/FetchHttpClient.d.ts +4 -0
- package/dist/unstable/http/FetchHttpClient.d.ts.map +1 -1
- package/dist/unstable/http/FetchHttpClient.js +4 -0
- package/dist/unstable/http/FetchHttpClient.js.map +1 -1
- package/dist/unstable/http/Headers.d.ts +60 -0
- package/dist/unstable/http/Headers.d.ts.map +1 -1
- package/dist/unstable/http/Headers.js +24 -0
- package/dist/unstable/http/Headers.js.map +1 -1
- package/dist/unstable/http/HttpBody.d.ts +32 -0
- package/dist/unstable/http/HttpBody.d.ts.map +1 -1
- package/dist/unstable/http/HttpBody.js +22 -0
- package/dist/unstable/http/HttpBody.js.map +1 -1
- package/dist/unstable/http/HttpClient.d.ts +44 -0
- package/dist/unstable/http/HttpClient.d.ts.map +1 -1
- package/dist/unstable/http/HttpClient.js +14 -0
- package/dist/unstable/http/HttpClient.js.map +1 -1
- package/dist/unstable/http/HttpClientRequest.d.ts +2 -0
- package/dist/unstable/http/HttpClientRequest.d.ts.map +1 -1
- package/dist/unstable/http/HttpClientRequest.js +2 -0
- package/dist/unstable/http/HttpClientRequest.js.map +1 -1
- package/dist/unstable/http/HttpClientResponse.d.ts +6 -0
- package/dist/unstable/http/HttpClientResponse.d.ts.map +1 -1
- package/dist/unstable/http/HttpClientResponse.js +6 -0
- package/dist/unstable/http/HttpClientResponse.js.map +1 -1
- package/dist/unstable/http/HttpEffect.d.ts +4 -0
- package/dist/unstable/http/HttpEffect.d.ts.map +1 -1
- package/dist/unstable/http/HttpEffect.js +4 -0
- package/dist/unstable/http/HttpEffect.js.map +1 -1
- package/dist/unstable/http/HttpPlatform.d.ts +2 -0
- package/dist/unstable/http/HttpPlatform.d.ts.map +1 -1
- package/dist/unstable/http/HttpPlatform.js +2 -0
- package/dist/unstable/http/HttpPlatform.js.map +1 -1
- package/dist/unstable/http/HttpRouter.d.ts +54 -16
- package/dist/unstable/http/HttpRouter.d.ts.map +1 -1
- package/dist/unstable/http/HttpRouter.js +26 -1
- package/dist/unstable/http/HttpRouter.js.map +1 -1
- package/dist/unstable/http/HttpServer.d.ts +35 -1
- package/dist/unstable/http/HttpServer.d.ts.map +1 -1
- package/dist/unstable/http/HttpServer.js +17 -1
- package/dist/unstable/http/HttpServer.js.map +1 -1
- package/dist/unstable/http/HttpServerError.d.ts +17 -3
- package/dist/unstable/http/HttpServerError.d.ts.map +1 -1
- package/dist/unstable/http/HttpServerError.js +16 -0
- package/dist/unstable/http/HttpServerError.js.map +1 -1
- package/dist/unstable/http/HttpServerRequest.d.ts +30 -0
- package/dist/unstable/http/HttpServerRequest.d.ts.map +1 -1
- package/dist/unstable/http/HttpServerRequest.js +28 -0
- package/dist/unstable/http/HttpServerRequest.js.map +1 -1
- package/dist/unstable/http/HttpServerRespondable.d.ts +8 -0
- package/dist/unstable/http/HttpServerRespondable.d.ts.map +1 -1
- package/dist/unstable/http/HttpServerRespondable.js +6 -0
- package/dist/unstable/http/HttpServerRespondable.js.map +1 -1
- package/dist/unstable/http/HttpServerResponse.d.ts +96 -0
- package/dist/unstable/http/HttpServerResponse.d.ts.map +1 -1
- package/dist/unstable/http/HttpServerResponse.js +50 -0
- package/dist/unstable/http/HttpServerResponse.js.map +1 -1
- package/dist/unstable/http/HttpTraceContext.d.ts +12 -0
- package/dist/unstable/http/HttpTraceContext.d.ts.map +1 -1
- package/dist/unstable/http/HttpTraceContext.js +10 -0
- package/dist/unstable/http/HttpTraceContext.js.map +1 -1
- package/dist/unstable/http/Multipart.d.ts +49 -2
- package/dist/unstable/http/Multipart.d.ts.map +1 -1
- package/dist/unstable/http/Multipart.js +35 -2
- package/dist/unstable/http/Multipart.js.map +1 -1
- package/dist/unstable/http/Template.d.ts +14 -0
- package/dist/unstable/http/Template.d.ts.map +1 -1
- package/dist/unstable/http/Template.js +4 -0
- package/dist/unstable/http/Template.js.map +1 -1
- package/dist/unstable/http/UrlParams.d.ts +64 -0
- package/dist/unstable/http/UrlParams.d.ts.map +1 -1
- package/dist/unstable/http/UrlParams.js +28 -0
- package/dist/unstable/http/UrlParams.js.map +1 -1
- package/dist/unstable/httpapi/HttpApi.d.ts +10 -4
- package/dist/unstable/httpapi/HttpApi.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApi.js +4 -0
- package/dist/unstable/httpapi/HttpApi.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiBuilder.d.ts +9 -4
- package/dist/unstable/httpapi/HttpApiBuilder.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiBuilder.js +5 -4
- package/dist/unstable/httpapi/HttpApiBuilder.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiEndpoint.d.ts +2 -0
- package/dist/unstable/httpapi/HttpApiEndpoint.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiEndpoint.js +2 -0
- package/dist/unstable/httpapi/HttpApiEndpoint.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiGroup.d.ts +23 -14
- package/dist/unstable/httpapi/HttpApiGroup.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiGroup.js +6 -3
- package/dist/unstable/httpapi/HttpApiGroup.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiMiddleware.d.ts +14 -0
- package/dist/unstable/httpapi/HttpApiMiddleware.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiMiddleware.js +6 -0
- package/dist/unstable/httpapi/HttpApiMiddleware.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiScalar.d.ts +38 -15
- package/dist/unstable/httpapi/HttpApiScalar.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiScalar.js +4 -0
- package/dist/unstable/httpapi/HttpApiScalar.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiSchema.d.ts +14 -3
- package/dist/unstable/httpapi/HttpApiSchema.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiSchema.js +10 -0
- package/dist/unstable/httpapi/HttpApiSchema.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiSecurity.d.ts +17 -11
- package/dist/unstable/httpapi/HttpApiSecurity.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiSecurity.js +17 -11
- package/dist/unstable/httpapi/HttpApiSecurity.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiSwagger.d.ts +2 -4
- package/dist/unstable/httpapi/HttpApiSwagger.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiSwagger.js +2 -4
- package/dist/unstable/httpapi/HttpApiSwagger.js.map +1 -1
- package/dist/unstable/httpapi/HttpApiTest.d.ts +2 -0
- package/dist/unstable/httpapi/HttpApiTest.d.ts.map +1 -1
- package/dist/unstable/httpapi/HttpApiTest.js +2 -0
- package/dist/unstable/httpapi/HttpApiTest.js.map +1 -1
- package/dist/unstable/httpapi/OpenApi.d.ts +2 -0
- package/dist/unstable/httpapi/OpenApi.d.ts.map +1 -1
- package/dist/unstable/httpapi/OpenApi.js +2 -0
- package/dist/unstable/httpapi/OpenApi.js.map +1 -1
- package/dist/unstable/observability/Otlp.d.ts +2 -0
- package/dist/unstable/observability/Otlp.d.ts.map +1 -1
- package/dist/unstable/observability/Otlp.js +2 -0
- package/dist/unstable/observability/Otlp.js.map +1 -1
- package/dist/unstable/observability/OtlpExporter.d.ts +2 -0
- package/dist/unstable/observability/OtlpExporter.d.ts.map +1 -1
- package/dist/unstable/observability/OtlpExporter.js +2 -0
- package/dist/unstable/observability/OtlpExporter.js.map +1 -1
- package/dist/unstable/observability/OtlpLogger.d.ts +4 -0
- package/dist/unstable/observability/OtlpLogger.d.ts.map +1 -1
- package/dist/unstable/observability/OtlpLogger.js +4 -0
- package/dist/unstable/observability/OtlpLogger.js.map +1 -1
- package/dist/unstable/observability/OtlpMetrics.d.ts +8 -9
- package/dist/unstable/observability/OtlpMetrics.d.ts.map +1 -1
- package/dist/unstable/observability/OtlpMetrics.js +3 -3
- package/dist/unstable/observability/OtlpMetrics.js.map +1 -1
- package/dist/unstable/observability/OtlpResource.d.ts +8 -0
- package/dist/unstable/observability/OtlpResource.d.ts.map +1 -1
- package/dist/unstable/observability/OtlpResource.js +8 -0
- package/dist/unstable/observability/OtlpResource.js.map +1 -1
- package/dist/unstable/observability/OtlpTracer.d.ts +3 -2
- package/dist/unstable/observability/OtlpTracer.d.ts.map +1 -1
- package/dist/unstable/observability/OtlpTracer.js +3 -2
- package/dist/unstable/observability/OtlpTracer.js.map +1 -1
- package/dist/unstable/observability/PrometheusMetrics.d.ts +6 -2
- package/dist/unstable/observability/PrometheusMetrics.d.ts.map +1 -1
- package/dist/unstable/observability/PrometheusMetrics.js +6 -2
- package/dist/unstable/observability/PrometheusMetrics.js.map +1 -1
- package/dist/unstable/persistence/KeyValueStore.d.ts +10 -0
- package/dist/unstable/persistence/KeyValueStore.d.ts.map +1 -1
- package/dist/unstable/persistence/KeyValueStore.js +8 -0
- package/dist/unstable/persistence/KeyValueStore.js.map +1 -1
- package/dist/unstable/persistence/Persistable.d.ts +2 -0
- package/dist/unstable/persistence/Persistable.d.ts.map +1 -1
- package/dist/unstable/persistence/Persistable.js +2 -0
- package/dist/unstable/persistence/Persistable.js.map +1 -1
- package/dist/unstable/persistence/PersistedCache.d.ts +2 -0
- package/dist/unstable/persistence/PersistedCache.d.ts.map +1 -1
- package/dist/unstable/persistence/PersistedCache.js +2 -0
- package/dist/unstable/persistence/PersistedCache.js.map +1 -1
- package/dist/unstable/persistence/PersistedQueue.d.ts +21 -6
- package/dist/unstable/persistence/PersistedQueue.d.ts.map +1 -1
- package/dist/unstable/persistence/PersistedQueue.js +10 -0
- package/dist/unstable/persistence/PersistedQueue.js.map +1 -1
- package/dist/unstable/persistence/Persistence.d.ts +14 -0
- package/dist/unstable/persistence/Persistence.d.ts.map +1 -1
- package/dist/unstable/persistence/Persistence.js +14 -0
- package/dist/unstable/persistence/Persistence.js.map +1 -1
- package/dist/unstable/persistence/RateLimiter.d.ts +6 -3
- package/dist/unstable/persistence/RateLimiter.d.ts.map +1 -1
- package/dist/unstable/persistence/RateLimiter.js +4 -0
- package/dist/unstable/persistence/RateLimiter.js.map +1 -1
- package/dist/unstable/persistence/Redis.d.ts +6 -0
- package/dist/unstable/persistence/Redis.d.ts.map +1 -1
- package/dist/unstable/persistence/Redis.js +4 -0
- package/dist/unstable/persistence/Redis.js.map +1 -1
- package/dist/unstable/process/ChildProcess.d.ts +70 -19
- package/dist/unstable/process/ChildProcess.d.ts.map +1 -1
- package/dist/unstable/process/ChildProcess.js +10 -0
- package/dist/unstable/process/ChildProcess.js.map +1 -1
- package/dist/unstable/process/ChildProcessSpawner.d.ts +20 -4
- package/dist/unstable/process/ChildProcessSpawner.d.ts.map +1 -1
- package/dist/unstable/process/ChildProcessSpawner.js.map +1 -1
- package/dist/unstable/reactivity/Atom.d.ts +105 -14
- package/dist/unstable/reactivity/Atom.d.ts.map +1 -1
- package/dist/unstable/reactivity/Atom.js +53 -8
- package/dist/unstable/reactivity/Atom.js.map +1 -1
- package/dist/unstable/reactivity/AtomHttpApi.d.ts +4 -0
- package/dist/unstable/reactivity/AtomHttpApi.d.ts.map +1 -1
- package/dist/unstable/reactivity/AtomHttpApi.js +2 -0
- package/dist/unstable/reactivity/AtomHttpApi.js.map +1 -1
- package/dist/unstable/reactivity/AtomRef.d.ts +8 -0
- package/dist/unstable/reactivity/AtomRef.d.ts.map +1 -1
- package/dist/unstable/reactivity/AtomRef.js +2 -0
- package/dist/unstable/reactivity/AtomRef.js.map +1 -1
- package/dist/unstable/reactivity/AtomRegistry.d.ts +32 -0
- package/dist/unstable/reactivity/AtomRegistry.d.ts.map +1 -1
- package/dist/unstable/reactivity/AtomRegistry.js +12 -0
- package/dist/unstable/reactivity/AtomRegistry.js.map +1 -1
- package/dist/unstable/reactivity/AtomRpc.d.ts +8 -6
- package/dist/unstable/reactivity/AtomRpc.d.ts.map +1 -1
- package/dist/unstable/reactivity/AtomRpc.js +4 -3
- package/dist/unstable/reactivity/AtomRpc.js.map +1 -1
- package/dist/unstable/reactivity/Hydration.d.ts +6 -0
- package/dist/unstable/reactivity/Hydration.d.ts.map +1 -1
- package/dist/unstable/reactivity/Hydration.js +4 -0
- package/dist/unstable/reactivity/Hydration.js.map +1 -1
- package/dist/unstable/reactivity/Reactivity.d.ts +27 -3
- package/dist/unstable/reactivity/Reactivity.d.ts.map +1 -1
- package/dist/unstable/reactivity/Reactivity.js +15 -3
- package/dist/unstable/reactivity/Reactivity.js.map +1 -1
- package/dist/unstable/rpc/Rpc.d.ts +38 -2
- package/dist/unstable/rpc/Rpc.d.ts.map +1 -1
- package/dist/unstable/rpc/Rpc.js +12 -2
- package/dist/unstable/rpc/Rpc.js.map +1 -1
- package/dist/unstable/rpc/RpcSerialization.d.ts +6 -0
- package/dist/unstable/rpc/RpcSerialization.d.ts.map +1 -1
- package/dist/unstable/rpc/RpcSerialization.js +6 -0
- package/dist/unstable/rpc/RpcSerialization.js.map +1 -1
- package/dist/unstable/rpc/RpcServer.d.ts +5 -3
- package/dist/unstable/rpc/RpcServer.d.ts.map +1 -1
- package/dist/unstable/rpc/RpcServer.js +5 -3
- package/dist/unstable/rpc/RpcServer.js.map +1 -1
- package/dist/unstable/schema/Model.d.ts +43 -12
- package/dist/unstable/schema/Model.d.ts.map +1 -1
- package/dist/unstable/schema/Model.js +41 -12
- package/dist/unstable/schema/Model.js.map +1 -1
- package/dist/unstable/sql/SqlClient.d.ts.map +1 -1
- package/dist/unstable/sql/SqlResolver.d.ts +6 -4
- package/dist/unstable/sql/SqlResolver.d.ts.map +1 -1
- package/dist/unstable/sql/SqlResolver.js +6 -4
- package/dist/unstable/sql/SqlResolver.js.map +1 -1
- package/dist/unstable/sql/Statement.d.ts +8 -4
- package/dist/unstable/sql/Statement.d.ts.map +1 -1
- package/dist/unstable/sql/Statement.js.map +1 -1
- package/dist/unstable/workflow/DurableClock.d.ts +1 -1
- package/dist/unstable/workflow/DurableDeferred.d.ts +3 -0
- package/dist/unstable/workflow/DurableDeferred.d.ts.map +1 -1
- package/dist/unstable/workflow/DurableDeferred.js +3 -0
- package/dist/unstable/workflow/DurableDeferred.js.map +1 -1
- package/dist/unstable/workflow/Workflow.d.ts +42 -34
- package/dist/unstable/workflow/Workflow.d.ts.map +1 -1
- package/dist/unstable/workflow/Workflow.js +18 -19
- package/dist/unstable/workflow/Workflow.js.map +1 -1
- package/package.json +1 -1
- package/src/Array.ts +454 -0
- package/src/BigDecimal.ts +87 -33
- package/src/BigInt.ts +71 -14
- package/src/Boolean.ts +4 -0
- package/src/Brand.ts +16 -11
- package/src/Cache.ts +17 -1
- package/src/Cause.ts +95 -3
- package/src/Channel.ts +326 -0
- package/src/ChannelSchema.ts +24 -0
- package/src/Chunk.ts +59 -22
- package/src/Combiner.ts +75 -71
- package/src/Config.ts +167 -46
- package/src/ConfigProvider.ts +235 -158
- package/src/Console.ts +25 -99
- package/src/Context.ts +4 -4
- package/src/Cron.ts +42 -16
- package/src/Crypto.ts +6 -0
- package/src/Data.ts +132 -70
- package/src/DateTime.ts +227 -14
- package/src/Deferred.ts +94 -27
- package/src/Differ.ts +2 -0
- package/src/Duration.ts +64 -6
- package/src/Effect.ts +909 -605
- package/src/Effectable.ts +3 -1
- package/src/Encoding.ts +16 -0
- package/src/Equal.ts +52 -40
- package/src/Equivalence.ts +190 -153
- package/src/ErrorReporter.ts +35 -14
- package/src/ExecutionPlan.ts +10 -3
- package/src/Exit.ts +212 -6
- package/src/Fiber.ts +8 -0
- package/src/FiberHandle.ts +46 -23
- package/src/FiberMap.ts +43 -4
- package/src/FiberSet.ts +21 -6
- package/src/FileSystem.ts +64 -0
- package/src/Filter.ts +53 -21
- package/src/Formatter.ts +21 -22
- package/src/Function.ts +67 -75
- package/src/Graph.ts +51 -13
- package/src/HKT.ts +22 -21
- package/src/Hash.ts +33 -10
- package/src/HashMap.ts +50 -9
- package/src/HashRing.ts +4 -0
- package/src/HashSet.ts +2 -0
- package/src/Inspectable.ts +15 -2
- package/src/Iterable.ts +104 -22
- package/src/JsonPatch.ts +61 -80
- package/src/JsonPointer.ts +16 -20
- package/src/JsonSchema.ts +123 -73
- package/src/Latch.ts +28 -2
- package/src/Layer.ts +781 -335
- package/src/LogLevel.ts +86 -13
- package/src/Logger.ts +71 -51
- package/src/ManagedRuntime.ts +12 -0
- package/src/Match.ts +83 -1
- package/src/Metric.ts +105 -12
- package/src/MutableHashMap.ts +18 -0
- package/src/MutableHashSet.ts +2 -0
- package/src/MutableList.ts +24 -6
- package/src/MutableRef.ts +2 -0
- package/src/Newtype.ts +69 -30
- package/src/NonEmptyIterable.ts +6 -0
- package/src/Number.ts +16 -30
- package/src/Optic.ts +90 -40
- package/src/Option.ts +121 -111
- package/src/Order.ts +169 -167
- package/src/Ordering.ts +4 -0
- package/src/PartitionedSemaphore.ts +7 -5
- package/src/Path.ts +8 -0
- package/src/Pipeable.ts +10 -0
- package/src/PlatformError.ts +12 -0
- package/src/Pool.ts +30 -16
- package/src/Predicate.ts +520 -352
- package/src/PrimaryKey.ts +4 -0
- package/src/PubSub.ts +23 -5
- package/src/Pull.ts +16 -0
- package/src/Queue.ts +44 -0
- package/src/Random.ts +25 -6
- package/src/RcMap.ts +10 -6
- package/src/RcRef.ts +3 -1
- package/src/Record.ts +24 -3
- package/src/Redactable.ts +54 -41
- package/src/Redacted.ts +10 -0
- package/src/Reducer.ts +20 -11
- package/src/Ref.ts +95 -58
- package/src/References.ts +18 -1
- package/src/Request.ts +3 -3
- package/src/RequestResolver.ts +8 -22
- package/src/Resource.ts +2 -0
- package/src/Result.ts +192 -6
- package/src/Runtime.ts +14 -11
- package/src/Schedule.ts +35 -3
- package/src/Scheduler.ts +22 -19
- package/src/Schema.ts +547 -130
- package/src/SchemaAST.ts +123 -65
- package/src/SchemaGetter.ts +269 -234
- package/src/SchemaIssue.ts +48 -46
- package/src/SchemaParser.ts +58 -0
- package/src/SchemaRepresentation.ts +198 -96
- package/src/SchemaTransformation.ts +272 -203
- package/src/SchemaUtils.ts +2 -0
- package/src/Scope.ts +19 -1
- package/src/ScopedCache.ts +56 -0
- package/src/ScopedRef.ts +9 -3
- package/src/Semaphore.ts +6 -0
- package/src/Sink.ts +108 -0
- package/src/Stdio.ts +7 -3
- package/src/Stream.ts +464 -16
- package/src/String.ts +14 -0
- package/src/Struct.ts +371 -191
- package/src/SubscriptionRef.ts +7 -1
- package/src/SynchronizedRef.ts +2 -0
- package/src/Tracer.ts +17 -27
- package/src/Trie.ts +23 -9
- package/src/Tuple.ts +287 -144
- package/src/TxChunk.ts +182 -93
- package/src/TxDeferred.ts +3 -4
- package/src/TxHashMap.ts +171 -90
- package/src/TxHashSet.ts +36 -35
- package/src/TxPriorityQueue.ts +2 -0
- package/src/TxPubSub.ts +36 -35
- package/src/TxQueue.ts +77 -114
- package/src/TxRef.ts +4 -0
- package/src/TxSemaphore.ts +66 -27
- package/src/Types.ts +202 -75
- package/src/UndefinedOr.ts +31 -29
- package/src/Unify.ts +28 -0
- package/src/Utils.ts +29 -35
- package/src/index.ts +18 -7
- package/src/testing/TestClock.ts +16 -16
- package/src/testing/TestConsole.ts +2 -0
- package/src/testing/TestSchema.ts +43 -55
- package/src/unstable/ai/AiError.ts +62 -11
- package/src/unstable/ai/AnthropicStructuredOutput.ts +4 -4
- package/src/unstable/ai/Chat.ts +29 -1
- package/src/unstable/ai/IdGenerator.ts +10 -0
- package/src/unstable/ai/LanguageModel.ts +32 -46
- package/src/unstable/ai/McpSchema.ts +84 -32
- package/src/unstable/ai/McpServer.ts +8 -0
- package/src/unstable/ai/Model.ts +9 -5
- package/src/unstable/ai/OpenAiStructuredOutput.ts +3 -2
- package/src/unstable/ai/Prompt.ts +62 -35
- package/src/unstable/ai/Response.ts +40 -21
- package/src/unstable/ai/ResponseIdTracker.ts +8 -0
- package/src/unstable/ai/Telemetry.ts +30 -5
- package/src/unstable/ai/Tokenizer.ts +6 -0
- package/src/unstable/ai/Tool.ts +68 -0
- package/src/unstable/ai/Toolkit.ts +12 -0
- package/src/unstable/cli/Argument.ts +14 -4
- package/src/unstable/cli/CliError.ts +6 -0
- package/src/unstable/cli/Command.ts +128 -12
- package/src/unstable/cli/Flag.ts +31 -14
- package/src/unstable/cli/Param.ts +96 -9
- package/src/unstable/cli/Primitive.ts +10 -0
- package/src/unstable/cli/Prompt.ts +47 -40
- package/src/unstable/cli/internal/command.ts +11 -2
- package/src/unstable/cli/internal/completions/descriptor.ts +3 -0
- package/src/unstable/cli/internal/parser.ts +8 -1
- package/src/unstable/cluster/ClusterCron.ts +10 -1
- package/src/unstable/cluster/ClusterSchema.ts +8 -0
- package/src/unstable/cluster/ClusterWorkflowEngine.ts +4 -0
- package/src/unstable/cluster/DeliverAt.ts +3 -4
- package/src/unstable/cluster/Entity.ts +24 -0
- package/src/unstable/cluster/EntityProxy.ts +10 -4
- package/src/unstable/cluster/EntityProxyServer.ts +6 -0
- package/src/unstable/cluster/EntityResource.ts +10 -0
- package/src/unstable/cluster/Envelope.ts +16 -0
- package/src/unstable/cluster/HttpRunner.ts +16 -0
- package/src/unstable/cluster/K8sHttpClient.ts +8 -0
- package/src/unstable/cluster/Message.ts +24 -0
- package/src/unstable/cluster/MessageStorage.ts +44 -10
- package/src/unstable/cluster/Reply.ts +6 -6
- package/src/unstable/cluster/Runner.ts +2 -0
- package/src/unstable/cluster/RunnerHealth.ts +13 -2
- package/src/unstable/cluster/RunnerServer.ts +8 -8
- package/src/unstable/cluster/RunnerStorage.ts +2 -0
- package/src/unstable/cluster/ShardId.ts +4 -0
- package/src/unstable/cluster/Snowflake.ts +2 -0
- package/src/unstable/cluster/TestRunner.ts +3 -2
- package/src/unstable/devtools/DevToolsSchema.ts +34 -2
- package/src/unstable/devtools/DevToolsServer.ts +4 -0
- package/src/unstable/encoding/Msgpack.ts +24 -0
- package/src/unstable/encoding/Ndjson.ts +46 -2
- package/src/unstable/encoding/Sse.ts +24 -17
- package/src/unstable/eventlog/Event.ts +16 -0
- package/src/unstable/eventlog/EventGroup.ts +4 -0
- package/src/unstable/eventlog/EventJournal.ts +20 -0
- package/src/unstable/eventlog/EventLog.ts +22 -0
- package/src/unstable/eventlog/EventLogMessage.ts +10 -0
- package/src/unstable/eventlog/EventLogRemote.ts +4 -0
- package/src/unstable/eventlog/EventLogServer.ts +4 -0
- package/src/unstable/eventlog/EventLogServerEncrypted.ts +6 -0
- package/src/unstable/eventlog/EventLogServerUnencrypted.ts +8 -0
- package/src/unstable/eventlog/EventLogSessionAuth.ts +11 -1
- package/src/unstable/eventlog/SqlEventJournal.ts +2 -0
- package/src/unstable/eventlog/SqlEventLogServerEncrypted.ts +2 -0
- package/src/unstable/eventlog/SqlEventLogServerUnencrypted.ts +2 -0
- package/src/unstable/http/Cookies.ts +34 -0
- package/src/unstable/http/Etag.ts +4 -0
- package/src/unstable/http/FetchHttpClient.ts +4 -0
- package/src/unstable/http/Headers.ts +88 -0
- package/src/unstable/http/HttpBody.ts +32 -0
- package/src/unstable/http/HttpClient.ts +44 -0
- package/src/unstable/http/HttpClientRequest.ts +2 -0
- package/src/unstable/http/HttpClientResponse.ts +6 -0
- package/src/unstable/http/HttpEffect.ts +4 -0
- package/src/unstable/http/HttpPlatform.ts +2 -0
- package/src/unstable/http/HttpRouter.ts +54 -16
- package/src/unstable/http/HttpServer.ts +35 -1
- package/src/unstable/http/HttpServerError.ts +17 -3
- package/src/unstable/http/HttpServerRequest.ts +30 -0
- package/src/unstable/http/HttpServerRespondable.ts +8 -0
- package/src/unstable/http/HttpServerResponse.ts +96 -0
- package/src/unstable/http/HttpTraceContext.ts +12 -0
- package/src/unstable/http/Multipart.ts +49 -2
- package/src/unstable/http/Template.ts +14 -0
- package/src/unstable/http/UrlParams.ts +64 -0
- package/src/unstable/httpapi/HttpApi.ts +10 -4
- package/src/unstable/httpapi/HttpApiBuilder.ts +9 -4
- package/src/unstable/httpapi/HttpApiEndpoint.ts +2 -0
- package/src/unstable/httpapi/HttpApiGroup.ts +23 -14
- package/src/unstable/httpapi/HttpApiMiddleware.ts +14 -0
- package/src/unstable/httpapi/HttpApiScalar.ts +38 -15
- package/src/unstable/httpapi/HttpApiSchema.ts +14 -3
- package/src/unstable/httpapi/HttpApiSecurity.ts +17 -11
- package/src/unstable/httpapi/HttpApiSwagger.ts +2 -4
- package/src/unstable/httpapi/HttpApiTest.ts +2 -0
- package/src/unstable/httpapi/OpenApi.ts +2 -0
- package/src/unstable/observability/Otlp.ts +2 -0
- package/src/unstable/observability/OtlpExporter.ts +2 -0
- package/src/unstable/observability/OtlpLogger.ts +4 -0
- package/src/unstable/observability/OtlpMetrics.ts +8 -9
- package/src/unstable/observability/OtlpResource.ts +8 -0
- package/src/unstable/observability/OtlpTracer.ts +3 -2
- package/src/unstable/observability/PrometheusMetrics.ts +6 -2
- package/src/unstable/persistence/KeyValueStore.ts +10 -0
- package/src/unstable/persistence/Persistable.ts +2 -0
- package/src/unstable/persistence/PersistedCache.ts +2 -0
- package/src/unstable/persistence/PersistedQueue.ts +21 -6
- package/src/unstable/persistence/Persistence.ts +14 -0
- package/src/unstable/persistence/RateLimiter.ts +6 -3
- package/src/unstable/persistence/Redis.ts +6 -0
- package/src/unstable/process/ChildProcess.ts +70 -19
- package/src/unstable/process/ChildProcessSpawner.ts +20 -4
- package/src/unstable/reactivity/Atom.ts +119 -14
- package/src/unstable/reactivity/AtomHttpApi.ts +4 -0
- package/src/unstable/reactivity/AtomRef.ts +8 -0
- package/src/unstable/reactivity/AtomRegistry.ts +34 -0
- package/src/unstable/reactivity/AtomRpc.ts +8 -6
- package/src/unstable/reactivity/Hydration.ts +6 -0
- package/src/unstable/reactivity/Reactivity.ts +27 -3
- package/src/unstable/rpc/Rpc.ts +38 -2
- package/src/unstable/rpc/RpcSerialization.ts +6 -0
- package/src/unstable/rpc/RpcServer.ts +5 -3
- package/src/unstable/schema/Model.ts +43 -12
- package/src/unstable/sql/SqlClient.ts +1 -1
- package/src/unstable/sql/SqlResolver.ts +6 -4
- package/src/unstable/sql/Statement.ts +8 -4
- package/src/unstable/workflow/DurableClock.ts +1 -1
- package/src/unstable/workflow/DurableDeferred.ts +3 -0
- package/src/unstable/workflow/Workflow.ts +42 -34
package/dist/Number.d.ts
CHANGED
|
@@ -193,9 +193,7 @@ export declare const subtract: {
|
|
|
193
193
|
(self: number, that: number): number;
|
|
194
194
|
};
|
|
195
195
|
/**
|
|
196
|
-
* Provides a division operation on `number`s.
|
|
197
|
-
*
|
|
198
|
-
* Returns `Option.none()` if the divisor is `0`.
|
|
196
|
+
* Provides a division operation on `number`s, returning `Option.none()` if the divisor is `0`.
|
|
199
197
|
*
|
|
200
198
|
* **Example** (Dividing numbers safely)
|
|
201
199
|
*
|
|
@@ -211,9 +209,7 @@ export declare const subtract: {
|
|
|
211
209
|
*/
|
|
212
210
|
export declare const divide: {
|
|
213
211
|
/**
|
|
214
|
-
* Provides a division operation on `number`s.
|
|
215
|
-
*
|
|
216
|
-
* Returns `Option.none()` if the divisor is `0`.
|
|
212
|
+
* Provides a division operation on `number`s, returning `Option.none()` if the divisor is `0`.
|
|
217
213
|
*
|
|
218
214
|
* **Example** (Dividing numbers safely)
|
|
219
215
|
*
|
|
@@ -229,9 +225,7 @@ export declare const divide: {
|
|
|
229
225
|
*/
|
|
230
226
|
(that: number): (self: number) => Option.Option<number>;
|
|
231
227
|
/**
|
|
232
|
-
* Provides a division operation on `number`s.
|
|
233
|
-
*
|
|
234
|
-
* Returns `Option.none()` if the divisor is `0`.
|
|
228
|
+
* Provides a division operation on `number`s, returning `Option.none()` if the divisor is `0`.
|
|
235
229
|
*
|
|
236
230
|
* **Example** (Dividing numbers safely)
|
|
237
231
|
*
|
|
@@ -248,9 +242,7 @@ export declare const divide: {
|
|
|
248
242
|
(self: number, that: number): Option.Option<number>;
|
|
249
243
|
};
|
|
250
244
|
/**
|
|
251
|
-
* Provides an unsafe division operation on `number`s
|
|
252
|
-
*
|
|
253
|
-
* Throws a `RangeError` if the divisor is `0`.
|
|
245
|
+
* Provides an unsafe division operation on `number`s that throws a `RangeError` if the divisor is `0`.
|
|
254
246
|
*
|
|
255
247
|
* **Example** (Dividing numbers unsafely)
|
|
256
248
|
*
|
|
@@ -267,9 +259,7 @@ export declare const divide: {
|
|
|
267
259
|
*/
|
|
268
260
|
export declare const divideUnsafe: {
|
|
269
261
|
/**
|
|
270
|
-
* Provides an unsafe division operation on `number`s
|
|
271
|
-
*
|
|
272
|
-
* Throws a `RangeError` if the divisor is `0`.
|
|
262
|
+
* Provides an unsafe division operation on `number`s that throws a `RangeError` if the divisor is `0`.
|
|
273
263
|
*
|
|
274
264
|
* **Example** (Dividing numbers unsafely)
|
|
275
265
|
*
|
|
@@ -286,9 +276,7 @@ export declare const divideUnsafe: {
|
|
|
286
276
|
*/
|
|
287
277
|
(that: number): (self: number) => number;
|
|
288
278
|
/**
|
|
289
|
-
* Provides an unsafe division operation on `number`s
|
|
290
|
-
*
|
|
291
|
-
* Throws a `RangeError` if the divisor is `0`.
|
|
279
|
+
* Provides an unsafe division operation on `number`s that throws a `RangeError` if the divisor is `0`.
|
|
292
280
|
*
|
|
293
281
|
* **Example** (Dividing numbers unsafely)
|
|
294
282
|
*
|
|
@@ -355,9 +343,7 @@ export declare const decrement: (n: number) => number;
|
|
|
355
343
|
*/
|
|
356
344
|
export declare const Order: order.Order<number>;
|
|
357
345
|
/**
|
|
358
|
-
* An `Equivalence` instance for numbers
|
|
359
|
-
*
|
|
360
|
-
* `NaN` is considered equal to `NaN`.
|
|
346
|
+
* An `Equivalence` instance for numbers where `NaN` is considered equal to `NaN`.
|
|
361
347
|
*
|
|
362
348
|
* **Example** (Comparing numbers for equivalence)
|
|
363
349
|
*
|
|
@@ -663,6 +649,8 @@ export declare const between: {
|
|
|
663
649
|
/**
|
|
664
650
|
* Restricts the given `number` to be within the range specified by the `minimum` and `maximum` values.
|
|
665
651
|
*
|
|
652
|
+
* **Details**
|
|
653
|
+
*
|
|
666
654
|
* - If the `number` is less than the `minimum` value, the function returns the `minimum` value.
|
|
667
655
|
* - If the `number` is greater than the `maximum` value, the function returns the `maximum` value.
|
|
668
656
|
* - Otherwise, it returns the original `number`.
|
|
@@ -687,6 +675,8 @@ export declare const clamp: {
|
|
|
687
675
|
/**
|
|
688
676
|
* Restricts the given `number` to be within the range specified by the `minimum` and `maximum` values.
|
|
689
677
|
*
|
|
678
|
+
* **Details**
|
|
679
|
+
*
|
|
690
680
|
* - If the `number` is less than the `minimum` value, the function returns the `minimum` value.
|
|
691
681
|
* - If the `number` is greater than the `maximum` value, the function returns the `maximum` value.
|
|
692
682
|
* - Otherwise, it returns the original `number`.
|
|
@@ -714,6 +704,8 @@ export declare const clamp: {
|
|
|
714
704
|
/**
|
|
715
705
|
* Restricts the given `number` to be within the range specified by the `minimum` and `maximum` values.
|
|
716
706
|
*
|
|
707
|
+
* **Details**
|
|
708
|
+
*
|
|
717
709
|
* - If the `number` is less than the `minimum` value, the function returns the `minimum` value.
|
|
718
710
|
* - If the `number` is greater than the `maximum` value, the function returns the `maximum` value.
|
|
719
711
|
* - Otherwise, it returns the original `number`.
|
|
@@ -888,9 +880,7 @@ export declare const sumAll: (collection: Iterable<number>) => number;
|
|
|
888
880
|
*/
|
|
889
881
|
export declare const multiplyAll: (collection: Iterable<number>) => number;
|
|
890
882
|
/**
|
|
891
|
-
* Returns the remainder left over when one operand is divided by a second operand.
|
|
892
|
-
*
|
|
893
|
-
* It always takes the sign of the dividend.
|
|
883
|
+
* Returns the remainder left over when one operand is divided by a second operand, always taking the sign of the dividend.
|
|
894
884
|
*
|
|
895
885
|
* **Example** (Calculating remainders)
|
|
896
886
|
*
|
|
@@ -908,9 +898,7 @@ export declare const multiplyAll: (collection: Iterable<number>) => number;
|
|
|
908
898
|
*/
|
|
909
899
|
export declare const remainder: {
|
|
910
900
|
/**
|
|
911
|
-
* Returns the remainder left over when one operand is divided by a second operand.
|
|
912
|
-
*
|
|
913
|
-
* It always takes the sign of the dividend.
|
|
901
|
+
* Returns the remainder left over when one operand is divided by a second operand, always taking the sign of the dividend.
|
|
914
902
|
*
|
|
915
903
|
* **Example** (Calculating remainders)
|
|
916
904
|
*
|
|
@@ -928,9 +916,7 @@ export declare const remainder: {
|
|
|
928
916
|
*/
|
|
929
917
|
(divisor: number): (self: number) => number;
|
|
930
918
|
/**
|
|
931
|
-
* Returns the remainder left over when one operand is divided by a second operand.
|
|
932
|
-
*
|
|
933
|
-
* It always takes the sign of the dividend.
|
|
919
|
+
* Returns the remainder left over when one operand is divided by a second operand, always taking the sign of the dividend.
|
|
934
920
|
*
|
|
935
921
|
* **Example** (Calculating remainders)
|
|
936
922
|
*
|
package/dist/Number.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Number.d.ts","sourceRoot":"","sources":["../src/Number.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AACH,OAAO,KAAK,GAAG,MAAM,kBAAkB,CAAA;AAEvC,OAAO,KAAK,MAAM,MAAM,aAAa,CAAA;AACrC,OAAO,KAAK,KAAK,MAAM,YAAY,CAAA;AACnC,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,eAAe,CAAA;AAE7C,OAAO,KAAK,OAAO,MAAM,cAAc,CAAA;AAEvC;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,MAAM,mBAAoB,CAAA;AAEvC;;;;;;;;;;;;;;;GAeG;AACH,eAAO,MAAM,QAAQ,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,KAAK,IAAI,MAA2B,CAAA;AAE/E;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,GAAG,EAAE;IAChB;;;;;;;;;;;;;;OAcG;IACH,CAAC,IAAI,EAAE,MAAM,GAAG,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAA;IACxC;;;;;;;;;;;;;;OAcG;IACH,CAAC,IAAI,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,MAAM,CAAA;CAC0B,CAAA;AAEhE;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,QAAQ,EAAE;IACrB;;;;;;;;;;;;;;OAcG;IACH,CAAC,IAAI,EAAE,MAAM,GAAG,CAA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S,EAAE,MAAM,GAAG,CAAC,IAAI,EAAE,MAAM,KAAK,MAAM,CAAA;IAC7C;;;;;;;;;;;;;;;OAeG;IACH,CAAC,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,MAAM,CAAA;CAIzC,CAAA;AAEF;;;;;GAKG;AACH,eAAO,MAAM,UAAU,EAAE,OAAO,CAAC,OAAO,CAAC,MAAM,CAAoC,CAAA;AAEnF;;;;;GAKG;AACH,eAAO,MAAM,eAAe,EAAE,OAAO,CAAC,OAAO,CAAC,MAAM,CAOlD,CAAA;AAEF;;;;;GAKG;AACH,eAAO,MAAM,UAAU,EAAE,OAAO,CAAC,OAAO,CAAC,MAAM,CAAqD,CAAA;AAEpG;;;;;GAKG;AACH,eAAO,MAAM,UAAU,EAAE,OAAO,CAAC,OAAO,CAAC,MAAM,CAAoD,CAAA"}
|
package/dist/Number.js
CHANGED
|
@@ -95,9 +95,7 @@ export const multiply = /*#__PURE__*/dual(2, (self, that) => self * that);
|
|
|
95
95
|
*/
|
|
96
96
|
export const subtract = /*#__PURE__*/dual(2, (self, that) => self - that);
|
|
97
97
|
/**
|
|
98
|
-
* Provides a division operation on `number`s.
|
|
99
|
-
*
|
|
100
|
-
* Returns `Option.none()` if the divisor is `0`.
|
|
98
|
+
* Provides a division operation on `number`s, returning `Option.none()` if the divisor is `0`.
|
|
101
99
|
*
|
|
102
100
|
* **Example** (Dividing numbers safely)
|
|
103
101
|
*
|
|
@@ -113,9 +111,7 @@ export const subtract = /*#__PURE__*/dual(2, (self, that) => self - that);
|
|
|
113
111
|
*/
|
|
114
112
|
export const divide = /*#__PURE__*/dual(2, (self, that) => that === 0 ? Option.none() : Option.some(self / that));
|
|
115
113
|
/**
|
|
116
|
-
* Provides an unsafe division operation on `number`s
|
|
117
|
-
*
|
|
118
|
-
* Throws a `RangeError` if the divisor is `0`.
|
|
114
|
+
* Provides an unsafe division operation on `number`s that throws a `RangeError` if the divisor is `0`.
|
|
119
115
|
*
|
|
120
116
|
* **Example** (Dividing numbers unsafely)
|
|
121
117
|
*
|
|
@@ -181,9 +177,7 @@ export const decrement = n => n - 1;
|
|
|
181
177
|
*/
|
|
182
178
|
export const Order = order.Number;
|
|
183
179
|
/**
|
|
184
|
-
* An `Equivalence` instance for numbers
|
|
185
|
-
*
|
|
186
|
-
* `NaN` is considered equal to `NaN`.
|
|
180
|
+
* An `Equivalence` instance for numbers where `NaN` is considered equal to `NaN`.
|
|
187
181
|
*
|
|
188
182
|
* **Example** (Comparing numbers for equivalence)
|
|
189
183
|
*
|
|
@@ -294,6 +288,8 @@ export const between = /*#__PURE__*/order.isBetween(Order);
|
|
|
294
288
|
/**
|
|
295
289
|
* Restricts the given `number` to be within the range specified by the `minimum` and `maximum` values.
|
|
296
290
|
*
|
|
291
|
+
* **Details**
|
|
292
|
+
*
|
|
297
293
|
* - If the `number` is less than the `minimum` value, the function returns the `minimum` value.
|
|
298
294
|
* - If the `number` is greater than the `maximum` value, the function returns the `maximum` value.
|
|
299
295
|
* - Otherwise, it returns the original `number`.
|
|
@@ -413,9 +409,7 @@ export const multiplyAll = collection => {
|
|
|
413
409
|
return out;
|
|
414
410
|
};
|
|
415
411
|
/**
|
|
416
|
-
* Returns the remainder left over when one operand is divided by a second operand.
|
|
417
|
-
*
|
|
418
|
-
* It always takes the sign of the dividend.
|
|
412
|
+
* Returns the remainder left over when one operand is divided by a second operand, always taking the sign of the dividend.
|
|
419
413
|
*
|
|
420
414
|
* **Example** (Calculating remainders)
|
|
421
415
|
*
|
package/dist/Number.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Number.js","names":["Equ","dual","Option","order","predicate","Reducer","Number","globalThis","isNumber","sum","self","that","multiply","subtract","divide","none","some","divideUnsafe","getOrThrowWith","RangeError","increment","n","decrement","Order","Equivalence","isLessThan","isLessThanOrEqualTo","isGreaterThan","isGreaterThanOrEqualTo","between","isBetween","clamp","min","max","sign","sumAll","collection","out","multiplyAll","remainder","divisor","selfDecCount","decimalCount","divisorDecCount","decCount","selfInt","parseInt","toFixed","replace","divisorInt","Math","pow","s","toString","eIndex","indexOf","exp","slice","mantissaDecimals","split","length","nextPow2","nextPow","ceil","log","parse","NaN","Infinity","trim","isNaN","round","precision","factor","ReducerSum","make","a","b","ReducerMultiply","acc","ReducerMax","ReducerMin"],"sources":["../src/Number.ts"],"sourcesContent":[null],"mappings":"AAAA;;;;;;AAMA,OAAO,KAAKA,GAAG,MAAM,kBAAkB;AACvC,SAASC,IAAI,QAAQ,eAAe;AACpC,OAAO,KAAKC,MAAM,MAAM,aAAa;AACrC,OAAO,KAAKC,KAAK,MAAM,YAAY;AAEnC,OAAO,KAAKC,SAAS,MAAM,gBAAgB;AAC3C,OAAO,KAAKC,OAAO,MAAM,cAAc;AAEvC;;;;;;;;;;;;;;;;;;AAkBA,OAAO,MAAMC,MAAM,GAAGC,UAAU,CAACD,MAAM;AAEvC;;;;;;;;;;;;;;;;AAgBA,OAAO,MAAME,QAAQ,GAAwCJ,SAAS,CAACI,QAAQ;AAE/E;;;;;;;;;;;;;;;AAeA,OAAO,MAAMC,GAAG,gBAiCZR,IAAI,CAAC,CAAC,EAAE,CAACS,IAAY,EAAEC,IAAY,KAAaD,IAAI,GAAGC,IAAI,CAAC;AAEhE;;;;;;;;;;;;;;;AAeA,OAAO,MAAMC,QAAQ,gBAiCjBX,IAAI,CAAC,CAAC,EAAE,CAACS,IAAY,EAAEC,IAAY,KAAaD,IAAI,GAAGC,IAAI,CAAC;AAEhE;;;;;;;;;;;;;;;AAeA,OAAO,MAAME,QAAQ,gBAiCjBZ,IAAI,CAAC,CAAC,EAAE,CAACS,IAAY,EAAEC,IAAY,KAAaD,IAAI,GAAGC,IAAI,CAAC;AAEhE
|
|
1
|
+
{"version":3,"file":"Number.js","names":["Equ","dual","Option","order","predicate","Reducer","Number","globalThis","isNumber","sum","self","that","multiply","subtract","divide","none","some","divideUnsafe","getOrThrowWith","RangeError","increment","n","decrement","Order","Equivalence","isLessThan","isLessThanOrEqualTo","isGreaterThan","isGreaterThanOrEqualTo","between","isBetween","clamp","min","max","sign","sumAll","collection","out","multiplyAll","remainder","divisor","selfDecCount","decimalCount","divisorDecCount","decCount","selfInt","parseInt","toFixed","replace","divisorInt","Math","pow","s","toString","eIndex","indexOf","exp","slice","mantissaDecimals","split","length","nextPow2","nextPow","ceil","log","parse","NaN","Infinity","trim","isNaN","round","precision","factor","ReducerSum","make","a","b","ReducerMultiply","acc","ReducerMax","ReducerMin"],"sources":["../src/Number.ts"],"sourcesContent":[null],"mappings":"AAAA;;;;;;AAMA,OAAO,KAAKA,GAAG,MAAM,kBAAkB;AACvC,SAASC,IAAI,QAAQ,eAAe;AACpC,OAAO,KAAKC,MAAM,MAAM,aAAa;AACrC,OAAO,KAAKC,KAAK,MAAM,YAAY;AAEnC,OAAO,KAAKC,SAAS,MAAM,gBAAgB;AAC3C,OAAO,KAAKC,OAAO,MAAM,cAAc;AAEvC;;;;;;;;;;;;;;;;;;AAkBA,OAAO,MAAMC,MAAM,GAAGC,UAAU,CAACD,MAAM;AAEvC;;;;;;;;;;;;;;;;AAgBA,OAAO,MAAME,QAAQ,GAAwCJ,SAAS,CAACI,QAAQ;AAE/E;;;;;;;;;;;;;;;AAeA,OAAO,MAAMC,GAAG,gBAiCZR,IAAI,CAAC,CAAC,EAAE,CAACS,IAAY,EAAEC,IAAY,KAAaD,IAAI,GAAGC,IAAI,CAAC;AAEhE;;;;;;;;;;;;;;;AAeA,OAAO,MAAMC,QAAQ,gBAiCjBX,IAAI,CAAC,CAAC,EAAE,CAACS,IAAY,EAAEC,IAAY,KAAaD,IAAI,GAAGC,IAAI,CAAC;AAEhE;;;;;;;;;;;;;;;AAeA,OAAO,MAAME,QAAQ,gBAiCjBZ,IAAI,CAAC,CAAC,EAAE,CAACS,IAAY,EAAEC,IAAY,KAAaD,IAAI,GAAGC,IAAI,CAAC;AAEhE;;;;;;;;;;;;;;;AAeA,OAAO,MAAMG,MAAM,gBAiCfb,I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,EAAEC,CAAC,KAAKD,CAAC,GAAGC,CAAC,EAAE,CAAC,EAAGxC,UAAU,IAAI;EACtG,IAAI0C,GAAG,GAAG,CAAC;EACX,KAAK,MAAMzD,CAAC,IAAIe,UAAU,EAAE;IAC1B,IAAIf,CAAC,KAAK,CAAC,EAAE,OAAO,CAAC;IACrByD,GAAG,IAAIzD,CAAC;EACV;EACA,OAAOyD,GAAG;AACZ,CAAC,CAAC;AAEF;;;;;;AAMA,OAAO,MAAMC,UAAU,gBAA4B1E,OAAO,CAACqE,IAAI,CAAC,CAACC,CAAC,EAAEC,CAAC,KAAK1B,IAAI,CAACjB,GAAG,CAAC0C,CAAC,EAAEC,CAAC,CAAC,EAAE,CAACT,QAAQ,CAAC;AAEpG;;;;;;AAMA,OAAO,MAAMa,UAAU,gBAA4B3E,OAAO,CAACqE,IAAI,CAAC,CAACC,CAAC,EAAEC,CAAC,KAAK1B,IAAI,CAAClB,GAAG,CAAC2C,CAAC,EAAEC,CAAC,CAAC,EAAET,QAAQ,CAAC","ignoreList":[]}
|
package/dist/Optic.d.ts
CHANGED
|
@@ -101,12 +101,14 @@ import type { IsUnion } from "./Types.ts";
|
|
|
101
101
|
/**
|
|
102
102
|
* A lossless, reversible conversion between types `S` and `A`.
|
|
103
103
|
*
|
|
104
|
-
* When to use
|
|
104
|
+
* **When to use**
|
|
105
|
+
*
|
|
105
106
|
* - You have a pair of functions that convert back and forth without losing
|
|
106
107
|
* information (e.g. `Record ↔ entries`, `Celsius ↔ Fahrenheit`).
|
|
107
108
|
* - You want the strongest optic that can be composed with any other.
|
|
108
109
|
*
|
|
109
|
-
*
|
|
110
|
+
* **Details**
|
|
111
|
+
*
|
|
110
112
|
* - `get(s)` always succeeds and returns an `A`.
|
|
111
113
|
* - `set(a)` always succeeds and returns an `S`.
|
|
112
114
|
* - `get(set(a)) === a` and `set(get(s))` equals `s` (round-trip laws).
|
|
@@ -141,11 +143,13 @@ export interface Iso<in out S, in out A> extends Lens<S, A>, Prism<S, A> {
|
|
|
141
143
|
/**
|
|
142
144
|
* Creates an {@link Iso} from a pair of conversion functions.
|
|
143
145
|
*
|
|
144
|
-
* When to use
|
|
146
|
+
* **When to use**
|
|
147
|
+
*
|
|
145
148
|
* - You have two pure functions that form a lossless round-trip between `S`
|
|
146
149
|
* and `A`.
|
|
147
150
|
*
|
|
148
|
-
*
|
|
151
|
+
* **Details**
|
|
152
|
+
*
|
|
149
153
|
* - Does not mutate inputs.
|
|
150
154
|
* - The returned optic can be composed with any other optic.
|
|
151
155
|
*
|
|
@@ -177,12 +181,14 @@ export declare function makeIso<S, A>(get: (s: S) => A, set: (a: A) => S): Iso<S
|
|
|
177
181
|
/**
|
|
178
182
|
* Focuses on exactly one part `A` inside a whole `S`.
|
|
179
183
|
*
|
|
180
|
-
* When to use
|
|
184
|
+
* **When to use**
|
|
185
|
+
*
|
|
181
186
|
* - You always have a value to read (the part exists unconditionally).
|
|
182
187
|
* - You need the original `S` to produce the updated whole (unlike
|
|
183
188
|
* {@link Iso}).
|
|
184
189
|
*
|
|
185
|
-
*
|
|
190
|
+
* **Details**
|
|
191
|
+
*
|
|
186
192
|
* - `get(s)` always succeeds and returns `A`.
|
|
187
193
|
* - `replace(a, s)` returns a new `S` with the focused part replaced.
|
|
188
194
|
* - Extends {@link Optional}.
|
|
@@ -215,11 +221,13 @@ export interface Lens<in out S, in out A> extends Optional<S, A> {
|
|
|
215
221
|
/**
|
|
216
222
|
* Creates a {@link Lens} from a getter and a replacer.
|
|
217
223
|
*
|
|
218
|
-
* When to use
|
|
224
|
+
* **When to use**
|
|
225
|
+
*
|
|
219
226
|
* - You can always extract `A` from `S` and produce a new `S` by
|
|
220
227
|
* substituting a new `A`.
|
|
221
228
|
*
|
|
222
|
-
*
|
|
229
|
+
* **Details**
|
|
230
|
+
*
|
|
223
231
|
* - Does not mutate inputs.
|
|
224
232
|
* - `replace(a, s)` should return a structurally new `S` with `a` in place
|
|
225
233
|
* of the old focus.
|
|
@@ -252,12 +260,14 @@ export declare function makeLens<S, A>(get: (s: S) => A, replace: (a: A, s: S) =
|
|
|
252
260
|
* Focuses on a part `A` of `S` that may not be present (e.g. a union
|
|
253
261
|
* variant or a validated subset).
|
|
254
262
|
*
|
|
255
|
-
* When to use
|
|
263
|
+
* **When to use**
|
|
264
|
+
*
|
|
256
265
|
* - The focus is conditional — reading can fail (wrong variant, failed
|
|
257
266
|
* validation).
|
|
258
267
|
* - Building a new `S` from `A` does **not** require the original `S`.
|
|
259
268
|
*
|
|
260
|
-
*
|
|
269
|
+
* **Details**
|
|
270
|
+
*
|
|
261
271
|
* - `getResult(s)` returns `Result.Success<A>` when the focus matches, or
|
|
262
272
|
* `Result.Failure<string>` with an error message.
|
|
263
273
|
* - `set(a)` always succeeds and returns a new `S`.
|
|
@@ -296,11 +306,13 @@ export interface Prism<in out S, in out A> extends Optional<S, A> {
|
|
|
296
306
|
/**
|
|
297
307
|
* Creates a {@link Prism} from a fallible getter and an infallible setter.
|
|
298
308
|
*
|
|
299
|
-
* When to use
|
|
309
|
+
* **When to use**
|
|
310
|
+
*
|
|
300
311
|
* - Reading can fail (the part may not exist in `S`), but building `S`
|
|
301
312
|
* from `A` always succeeds.
|
|
302
313
|
*
|
|
303
|
-
*
|
|
314
|
+
* **Details**
|
|
315
|
+
*
|
|
304
316
|
* - Does not mutate inputs.
|
|
305
317
|
* - `getResult` should return `Result.fail(message)` on mismatch.
|
|
306
318
|
*
|
|
@@ -334,12 +346,14 @@ export declare function makePrism<S, A>(getResult: (s: S) => Result.Result<A, st
|
|
|
334
346
|
/**
|
|
335
347
|
* Creates a {@link Prism} from one or more `Schema` validation checks.
|
|
336
348
|
*
|
|
337
|
-
* When to use
|
|
349
|
+
* **When to use**
|
|
350
|
+
*
|
|
338
351
|
* - You want to narrow `T` to the subset that passes certain validation
|
|
339
352
|
* rules (e.g. positive integer).
|
|
340
353
|
* - You already have `Schema.isGreaterThan`, `Schema.isInt`, etc.
|
|
341
354
|
*
|
|
342
|
-
*
|
|
355
|
+
* **Details**
|
|
356
|
+
*
|
|
343
357
|
* - `getResult` runs all checks; fails with a combined error message when
|
|
344
358
|
* any check fails.
|
|
345
359
|
* - `set` is identity — the value passes through unchanged.
|
|
@@ -416,13 +430,15 @@ type ForbidUnion<A, Message extends string> = IsUnion<A> extends true ? [Message
|
|
|
416
430
|
/**
|
|
417
431
|
* The most general optic — both reading and writing can fail.
|
|
418
432
|
*
|
|
419
|
-
* When to use
|
|
433
|
+
* **When to use**
|
|
434
|
+
*
|
|
420
435
|
* - The focus may not exist in `S` **and** writing a new `A` back may also
|
|
421
436
|
* fail (e.g. the source no longer matches the expected shape).
|
|
422
437
|
* - As the base type: every optic ({@link Iso}, {@link Lens}, {@link Prism},
|
|
423
438
|
* {@link Traversal}) extends `Optional`.
|
|
424
439
|
*
|
|
425
|
-
*
|
|
440
|
+
* **Details**
|
|
441
|
+
*
|
|
426
442
|
* - `getResult(s)` returns `Result.Success<A>` or `Result.Failure<string>`.
|
|
427
443
|
* - `replaceResult(a, s)` returns `Result.Success<S>` or
|
|
428
444
|
* `Result.Failure<string>`.
|
|
@@ -459,9 +475,8 @@ type ForbidUnion<A, Message extends string> = IsUnion<A> extends true ? [Message
|
|
|
459
475
|
export interface Optional<in out S, in out A> {
|
|
460
476
|
readonly node: Node;
|
|
461
477
|
/**
|
|
462
|
-
* Attempts to read the focus `A` from the whole `S`.
|
|
463
|
-
*
|
|
464
|
-
* Returns `Result.Success<A>` when the focus exists, or
|
|
478
|
+
* Attempts to read the focus `A` from the whole `S`. Returns
|
|
479
|
+
* `Result.Success<A>` when the focus exists, or
|
|
465
480
|
* `Result.Failure<string>` with a descriptive error otherwise.
|
|
466
481
|
*/
|
|
467
482
|
readonly getResult: (s: S) => Result.Result<A, string>;
|
|
@@ -517,6 +532,8 @@ export interface Optional<in out S, in out A> {
|
|
|
517
532
|
/**
|
|
518
533
|
* Focuses on a property of the current struct/tuple focus.
|
|
519
534
|
*
|
|
535
|
+
* **Details**
|
|
536
|
+
*
|
|
520
537
|
* - On a {@link Lens}, returns a Lens.
|
|
521
538
|
* - On an {@link Optional}, returns an Optional.
|
|
522
539
|
* - Does **not** work on union types (compile error).
|
|
@@ -539,6 +556,8 @@ export interface Optional<in out S, in out A> {
|
|
|
539
556
|
* Focuses on a key where setting `undefined` **removes** the key from the
|
|
540
557
|
* struct (or splices the element from an array/tuple).
|
|
541
558
|
*
|
|
559
|
+
* **Details**
|
|
560
|
+
*
|
|
542
561
|
* - The focus type becomes `A[Key] | undefined`.
|
|
543
562
|
* - Does **not** work on union types (compile error).
|
|
544
563
|
*
|
|
@@ -563,6 +582,8 @@ export interface Optional<in out S, in out A> {
|
|
|
563
582
|
* Adds one or more `Schema` validation checks to the optic chain.
|
|
564
583
|
* `getResult` fails when any check fails; `set` passes through unchanged.
|
|
565
584
|
*
|
|
585
|
+
* **Details**
|
|
586
|
+
*
|
|
566
587
|
* - On a {@link Prism}, returns a Prism.
|
|
567
588
|
* - On an {@link Optional}, returns an Optional.
|
|
568
589
|
*
|
|
@@ -587,6 +608,8 @@ export interface Optional<in out S, in out A> {
|
|
|
587
608
|
/**
|
|
588
609
|
* Narrows the focus to a subtype `B` using a type guard.
|
|
589
610
|
*
|
|
611
|
+
* **Details**
|
|
612
|
+
*
|
|
590
613
|
* - On a {@link Prism}, returns a Prism.
|
|
591
614
|
* - On an {@link Optional}, returns an Optional.
|
|
592
615
|
* - Pass optional `annotations` to customize the error message.
|
|
@@ -616,6 +639,8 @@ export interface Optional<in out S, in out A> {
|
|
|
616
639
|
* Narrows the focus to the variant of a tagged union with the given
|
|
617
640
|
* `_tag` value.
|
|
618
641
|
*
|
|
642
|
+
* **Details**
|
|
643
|
+
*
|
|
619
644
|
* - On a {@link Prism}, returns a Prism.
|
|
620
645
|
* - On an {@link Optional}, returns an Optional.
|
|
621
646
|
* - Shorthand for `.refine(s => s._tag === tag)`.
|
|
@@ -654,6 +679,8 @@ export interface Optional<in out S, in out A> {
|
|
|
654
679
|
* Focuses on a key only if it exists (`Object.hasOwn`). Both
|
|
655
680
|
* `getResult` and `replaceResult` fail when the key is absent.
|
|
656
681
|
*
|
|
682
|
+
* **Details**
|
|
683
|
+
*
|
|
657
684
|
* Unlike `.key()`, which always succeeds on the read side, `.at()` is
|
|
658
685
|
* useful for Records or arrays where the key/index may not be present.
|
|
659
686
|
*
|
|
@@ -681,6 +708,8 @@ export interface Optional<in out S, in out A> {
|
|
|
681
708
|
/**
|
|
682
709
|
* Focuses on a subset of keys of the current struct focus.
|
|
683
710
|
*
|
|
711
|
+
* **Details**
|
|
712
|
+
*
|
|
684
713
|
* - On a {@link Lens}, returns a Lens.
|
|
685
714
|
* - On an {@link Optional}, returns an Optional.
|
|
686
715
|
* - Does **not** work on union types (compile error).
|
|
@@ -705,6 +734,8 @@ export interface Optional<in out S, in out A> {
|
|
|
705
734
|
/**
|
|
706
735
|
* Focuses on all keys **except** the specified ones.
|
|
707
736
|
*
|
|
737
|
+
* **Details**
|
|
738
|
+
*
|
|
708
739
|
* - On a {@link Lens}, returns a Lens.
|
|
709
740
|
* - On an {@link Optional}, returns an Optional.
|
|
710
741
|
* - Does **not** work on union types (compile error).
|
|
@@ -730,7 +761,6 @@ export interface Optional<in out S, in out A> {
|
|
|
730
761
|
omit<S, A, Keys extends ReadonlyArray<keyof A>>(this: Optional<S, A>, keys: Keys, ..._err: ForbidUnion<A, "cannot use `omit` on a union type">): Optional<S, Omit<A, Keys[number]>>;
|
|
731
762
|
/**
|
|
732
763
|
* Filters out `undefined` from the focus, producing a {@link Prism}.
|
|
733
|
-
*
|
|
734
764
|
* `getResult` fails when the focus is `undefined`.
|
|
735
765
|
*
|
|
736
766
|
* **Example** (filtering undefined)
|
|
@@ -754,12 +784,12 @@ export interface Optional<in out S, in out A> {
|
|
|
754
784
|
/**
|
|
755
785
|
* Focuses **all elements** of an array-like focus and optionally narrows
|
|
756
786
|
* to a subset using an element-level optic.
|
|
757
|
-
*
|
|
758
787
|
* Available only on {@link Traversal} (i.e. when `A` is
|
|
759
788
|
* `ReadonlyArray<Element>`). Returns a new Traversal focused on the
|
|
760
789
|
* selected elements.
|
|
761
790
|
*
|
|
762
|
-
*
|
|
791
|
+
* **Details**
|
|
792
|
+
*
|
|
763
793
|
* - **getResult** collects the values focused by `f(id<A>())` for each
|
|
764
794
|
* element. Non-focusable elements are skipped.
|
|
765
795
|
* - **replaceResult** expects exactly as many values as were collected by
|
|
@@ -796,6 +826,8 @@ export interface Optional<in out S, in out A> {
|
|
|
796
826
|
/**
|
|
797
827
|
* Applies a function to **every** element focused by the traversal.
|
|
798
828
|
*
|
|
829
|
+
* **Details**
|
|
830
|
+
*
|
|
799
831
|
* Available only on {@link Traversal}. Returns a function `(s: S) => S`.
|
|
800
832
|
* If the traversal cannot focus, the original `s` is returned unchanged.
|
|
801
833
|
*
|
|
@@ -827,10 +859,12 @@ export interface Optional<in out S, in out A> {
|
|
|
827
859
|
/**
|
|
828
860
|
* Creates an {@link Optional} from a fallible getter and a fallible setter.
|
|
829
861
|
*
|
|
830
|
-
* When to use
|
|
862
|
+
* **When to use**
|
|
863
|
+
*
|
|
831
864
|
* - Both reading and writing can fail.
|
|
832
865
|
*
|
|
833
|
-
*
|
|
866
|
+
* **Details**
|
|
867
|
+
*
|
|
834
868
|
* - Does not mutate inputs.
|
|
835
869
|
* - `getResult` should return `Result.fail(message)` on mismatch.
|
|
836
870
|
* - `set` should return `Result.fail(message)` when the update cannot be
|
|
@@ -868,11 +902,13 @@ export declare function makeOptional<S, A>(getResult: (s: S) => Result.Result<A,
|
|
|
868
902
|
/**
|
|
869
903
|
* An optic that focuses on **zero or more** elements of type `A` inside `S`.
|
|
870
904
|
*
|
|
871
|
-
* When to use
|
|
905
|
+
* **When to use**
|
|
906
|
+
*
|
|
872
907
|
* - You want to read/update multiple elements at once (e.g. all items in
|
|
873
908
|
* an array, or a filtered subset).
|
|
874
909
|
*
|
|
875
|
-
*
|
|
910
|
+
* **Details**
|
|
911
|
+
*
|
|
876
912
|
* - Technically `Optional<S, ReadonlyArray<A>>` — the focused value is an
|
|
877
913
|
* array of all matched elements.
|
|
878
914
|
* - Use `.forEach()` to add per-element sub-optics (filtering, drilling
|
|
@@ -909,11 +945,13 @@ export interface Traversal<in out S, in out A> extends Optional<S, ReadonlyArray
|
|
|
909
945
|
* Returns a function that extracts all elements focused by a
|
|
910
946
|
* {@link Traversal} as a plain mutable array.
|
|
911
947
|
*
|
|
912
|
-
* When to use
|
|
948
|
+
* **When to use**
|
|
949
|
+
*
|
|
913
950
|
* - You need the focused values as a simple `Array<A>` for further
|
|
914
951
|
* processing.
|
|
915
952
|
*
|
|
916
|
-
*
|
|
953
|
+
* **Details**
|
|
954
|
+
*
|
|
917
955
|
* - Returns an empty array when the traversal cannot focus.
|
|
918
956
|
* - Always returns a fresh array (safe to mutate).
|
|
919
957
|
* - Does not mutate the source.
|
|
@@ -947,11 +985,13 @@ export declare function getAll<S, A>(traversal: Traversal<S, A>): (s: S) => Arra
|
|
|
947
985
|
/**
|
|
948
986
|
* The identity {@link Iso}. Focuses on the whole value unchanged.
|
|
949
987
|
*
|
|
950
|
-
* When to use
|
|
988
|
+
* **When to use**
|
|
989
|
+
*
|
|
951
990
|
* - As the starting point of an optic chain: `Optic.id<S>().key("x")...`
|
|
952
991
|
* - Anywhere an `Iso<S, S>` is needed.
|
|
953
992
|
*
|
|
954
|
-
*
|
|
993
|
+
* **Details**
|
|
994
|
+
*
|
|
955
995
|
* - `get(s)` returns `s`.
|
|
956
996
|
* - `set(a)` returns `a`.
|
|
957
997
|
* - Singleton — every call returns the same instance.
|
|
@@ -979,11 +1019,13 @@ export declare function id<S>(): Iso<S, S>;
|
|
|
979
1019
|
* An {@link Iso} that converts a `Record<string, A>` to an array of
|
|
980
1020
|
* `[key, value]` entries and back.
|
|
981
1021
|
*
|
|
982
|
-
* When to use
|
|
1022
|
+
* **When to use**
|
|
1023
|
+
*
|
|
983
1024
|
* - You want to traverse or manipulate record entries as an array (e.g.
|
|
984
1025
|
* with `.forEach()`).
|
|
985
1026
|
*
|
|
986
|
-
*
|
|
1027
|
+
* **Details**
|
|
1028
|
+
*
|
|
987
1029
|
* - `get` uses `Object.entries`.
|
|
988
1030
|
* - `set` uses `Object.fromEntries`.
|
|
989
1031
|
* - Round-trip is lossless for `Record<string, A>`.
|
|
@@ -1012,11 +1054,13 @@ export declare function entries<A>(): Iso<Record<string, A>, ReadonlyArray<reado
|
|
|
1012
1054
|
/**
|
|
1013
1055
|
* A {@link Prism} that focuses on the value inside `Option.Some`.
|
|
1014
1056
|
*
|
|
1015
|
-
* When to use
|
|
1057
|
+
* **When to use**
|
|
1058
|
+
*
|
|
1016
1059
|
* - You have an `Option<A>` and want to read/update the inner value only
|
|
1017
1060
|
* when it is `Some`.
|
|
1018
1061
|
*
|
|
1019
|
-
*
|
|
1062
|
+
* **Details**
|
|
1063
|
+
*
|
|
1020
1064
|
* - `getResult` fails with an error message when the option is `None`.
|
|
1021
1065
|
* - `set(a)` wraps `a` in `Option.some(a)`.
|
|
1022
1066
|
*
|
|
@@ -1047,10 +1091,12 @@ export declare function some<A>(): Prism<Option.Option<A>, A>;
|
|
|
1047
1091
|
/**
|
|
1048
1092
|
* A {@link Prism} that focuses on `Option.None`, exposing `undefined`.
|
|
1049
1093
|
*
|
|
1050
|
-
* When to use
|
|
1094
|
+
* **When to use**
|
|
1095
|
+
*
|
|
1051
1096
|
* - You want to match or construct `None` values within an optic chain.
|
|
1052
1097
|
*
|
|
1053
|
-
*
|
|
1098
|
+
* **Details**
|
|
1099
|
+
*
|
|
1054
1100
|
* - `getResult` succeeds with `undefined` when the option is `None`.
|
|
1055
1101
|
* - `getResult` fails when the option is `Some`.
|
|
1056
1102
|
* - `set(undefined)` produces `Option.none()`.
|
|
@@ -1079,11 +1125,13 @@ export declare function none<A>(): Prism<Option.Option<A>, undefined>;
|
|
|
1079
1125
|
/**
|
|
1080
1126
|
* A {@link Prism} that focuses on the success value of a `Result`.
|
|
1081
1127
|
*
|
|
1082
|
-
* When to use
|
|
1128
|
+
* **When to use**
|
|
1129
|
+
*
|
|
1083
1130
|
* - You have a `Result<A, E>` and want to read/update `A` only when it
|
|
1084
1131
|
* is a `Success`.
|
|
1085
1132
|
*
|
|
1086
|
-
*
|
|
1133
|
+
* **Details**
|
|
1134
|
+
*
|
|
1087
1135
|
* - `getResult` fails when the result is a `Failure`.
|
|
1088
1136
|
* - `set(a)` produces `Result.succeed(a)`.
|
|
1089
1137
|
*
|
|
@@ -1111,11 +1159,13 @@ export declare function success<A, E>(): Prism<Result.Result<A, E>, A>;
|
|
|
1111
1159
|
/**
|
|
1112
1160
|
* A {@link Prism} that focuses on the failure value of a `Result`.
|
|
1113
1161
|
*
|
|
1114
|
-
* When to use
|
|
1162
|
+
* **When to use**
|
|
1163
|
+
*
|
|
1115
1164
|
* - You have a `Result<A, E>` and want to read/update `E` only when it
|
|
1116
1165
|
* is a `Failure`.
|
|
1117
1166
|
*
|
|
1118
|
-
*
|
|
1167
|
+
* **Details**
|
|
1168
|
+
*
|
|
1119
1169
|
* - `getResult` fails when the result is a `Success`.
|
|
1120
1170
|
* - `set(e)` produces `Result.fail(e)`.
|
|
1121
1171
|
*
|