Effection Logo
@effection-contrib/fxv0.1.0thefrontside/effection-contrib
JSR BadgeNPM Badge with published versionBundle size badgeDependency count badgeTree shaking support badge
import { } from "@effection-contrib/fx"

@effection-contrib/fx

A collection of utility functions to streamline asynchronous workflows. These functions were originally part of the starfx project and have been adapted for use with the Effection framework.

API

interface ParallelRet<T> extends Computation<Result<T>[]> {

  • sequence: Channel<Result<T>, void>;
  • immediate: Channel<Result<T>, void>;
}

function parallel(operations: Callable<T>[]):

function* safe(operator: Callable<T>): Operation<Result<T>>

function raceMap(opMap: OpMap): Operation<>

function* request(url: string | URL | Request, opts?: RequestInit):

function* json(response: Response):