MCPcopy Index your code
hub / github.com/Effect-TS/effect / makeRuntime

Function makeRuntime

packages/effect/src/FiberHandle.ts:133–148  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

131 * @categories constructors
132 */
133export const makeRuntime = <R, E = unknown, A = unknown>(): Effect.Effect<
134 <XE extends E, XA extends A>(
135 effect: Effect.Effect<XA, XE, R>,
136 options?:
137 | Runtime.RunForkOptions & {
138 readonly onlyIfMissing?: boolean | undefined
139 }
140 | undefined
141 ) => Fiber.RuntimeFiber<XA, XE>,
142 never,
143 Scope.Scope | R
144> =>
145 Effect.flatMap(
146 make<A, E>(),
147 (self) => runtime(self)<R>()
148 )
149
150/**
151 * Create an Effect run function that is backed by a FiberHandle.

Callers

nothing calls this directly

Calls 2

makeFunction · 0.70
runtimeFunction · 0.70

Tested by

no test coverage detected