@ucanto/interface
Advanced tools
Comparing version 9.0.0 to 10.0.0
@@ -305,3 +305,5 @@ import { Ability, Block as UCANBlock, ByteView, Capabilities, Capability, DID, Fact, Link as UCANLink, MultihashHasher, MultihashDigest, MultibaseDecoder, MultibaseEncoder, Phantom, Resource, Signature, SignatureView, Principal, MulticodecCode, SigAlg, ToJSON, SignatureJSON, JSONUnknown, Crypto, JSONObject } from '@ipld/dag-ucan'; | ||
} | ||
export interface Effects extends EffectsModel { | ||
export interface Effects { | ||
fork: readonly Effect[]; | ||
join?: Effect; | ||
} | ||
@@ -337,2 +339,6 @@ export interface InstructionModel<Op extends Ability = Ability, URI extends Resource = Resource, Input extends Record<string, unknown> = Record<string, unknown>> { | ||
export type Run = Link<ImpliedInvocationModel>; | ||
/** | ||
* Effect is either an invocation or a link to one. | ||
*/ | ||
export type Effect = Run | Invocation; | ||
export interface Do<T = unknown, X extends {} = {}> { | ||
@@ -348,4 +354,4 @@ out: Result<T, X>; | ||
effects: Effects; | ||
fork(fx: Run): ForkBuilder<T, X>; | ||
join(fx: Run): JoinBuilder<T, X>; | ||
fork(fx: Effect): ForkBuilder<T, X>; | ||
join(fx: Effect): JoinBuilder<T, X>; | ||
} | ||
@@ -358,4 +364,4 @@ export interface ErrorBuilder<T extends unknown = undefined, X extends {} = {}> { | ||
effects: Effects; | ||
fork(fx: Run): ForkBuilder<T, X>; | ||
join(fx: Run): JoinBuilder<T, X>; | ||
fork(fx: Effect): ForkBuilder<T, X>; | ||
join(fx: Effect): JoinBuilder<T, X>; | ||
} | ||
@@ -368,4 +374,4 @@ export interface ForkBuilder<T extends unknown = undefined, X extends {} = {}> { | ||
effects: Effects; | ||
fork(fx: Run): ForkBuilder<T, X>; | ||
join(fx: Run): JoinBuilder<T, X>; | ||
fork(fx: Effect): ForkBuilder<T, X>; | ||
join(fx: Effect): JoinBuilder<T, X>; | ||
} | ||
@@ -378,3 +384,3 @@ export interface JoinBuilder<T extends unknown = unknown, X extends {} = {}> { | ||
effects: Effects; | ||
fork(fx: Run): JoinBuilder<T, X>; | ||
fork(fx: Effect): JoinBuilder<T, X>; | ||
} | ||
@@ -381,0 +387,0 @@ /** |
{ | ||
"name": "@ucanto/interface", | ||
"description": "interface definitions for ucanto", | ||
"version": "9.0.0", | ||
"version": "10.0.0", | ||
"types": "./dist/src/lib.d.ts", | ||
@@ -6,0 +6,0 @@ "main": "./src/lib.js", |
@@ -487,3 +487,6 @@ import { | ||
export interface Effects extends EffectsModel {} | ||
export interface Effects { | ||
fork: readonly Effect[] | ||
join?: Effect | ||
} | ||
@@ -531,2 +534,7 @@ export interface InstructionModel< | ||
/** | ||
* Effect is either an invocation or a link to one. | ||
*/ | ||
export type Effect = Run | Invocation | ||
export interface Do<T = unknown, X extends {} = {}> { | ||
@@ -545,4 +553,4 @@ out: Result<T, X> | ||
fork(fx: Run): ForkBuilder<T, X> | ||
join(fx: Run): JoinBuilder<T, X> | ||
fork(fx: Effect): ForkBuilder<T, X> | ||
join(fx: Effect): JoinBuilder<T, X> | ||
} | ||
@@ -561,4 +569,4 @@ | ||
fork(fx: Run): ForkBuilder<T, X> | ||
join(fx: Run): JoinBuilder<T, X> | ||
fork(fx: Effect): ForkBuilder<T, X> | ||
join(fx: Effect): JoinBuilder<T, X> | ||
} | ||
@@ -573,4 +581,4 @@ | ||
fork(fx: Run): ForkBuilder<T, X> | ||
join(fx: Run): JoinBuilder<T, X> | ||
fork(fx: Effect): ForkBuilder<T, X> | ||
join(fx: Effect): JoinBuilder<T, X> | ||
} | ||
@@ -585,3 +593,3 @@ | ||
fork(fx: Run): JoinBuilder<T, X> | ||
fork(fx: Effect): JoinBuilder<T, X> | ||
} | ||
@@ -588,0 +596,0 @@ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
143167
2936