MCPcopy Create free account
hub / github.com/Effect-TS/effect / syncContext

Function syncContext

packages/effect/src/Layer.ts:1021–1022  ·  view source on GitHub ↗
(evaluate: LazyArg<Context.Context<A>>)

Source from the content-addressed store, hash-verified

1019 * @since 2.0.0
1020 */
1021export const syncContext = <A>(evaluate: LazyArg<Context.Context<A>>): Layer<A> =>
1022 fromBuildMemo(constant(internalEffect.sync(evaluate)))
1023
1024/**
1025 * Constructs a layer from an effect that produces a single service.

Callers 1

Layer.tsFile · 0.85

Calls 3

constantFunction · 0.90
fromBuildMemoFunction · 0.85
syncMethod · 0.45

Tested by

no test coverage detected