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

Function makeRuntime

packages/effect/src/FiberMap.ts:147–163  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

145 * @categories constructors
146 */
147export const makeRuntime = <R, K, E = unknown, A = unknown>(): Effect.Effect<
148 <XE extends E, XA extends A>(
149 key: K,
150 effect: Effect.Effect<XA, XE, R>,
151 options?:
152 | Runtime.RunForkOptions & {
153 readonly onlyIfMissing?: boolean | undefined
154 }
155 | undefined
156 ) => Fiber.RuntimeFiber<XA, XE>,
157 never,
158 Scope.Scope | R
159> =>
160 Effect.flatMap(
161 make<K, A, E>(),
162 (self) => runtime(self)<R>()
163 )
164
165/**
166 * Create an Effect run function that is backed by a FiberMap.

Callers

nothing calls this directly

Calls 2

makeFunction · 0.70
runtimeFunction · 0.70

Tested by

no test coverage detected