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

Function syncContext

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

Source from the content-addressed store, hash-verified

971 * @since 2.0.0
972 */
973export const syncContext = <A>(evaluate: LazyArg<Context.Context<A>>): Layer<A> =>
974 fromBuildMemo(constant(internalEffect.sync(evaluate)))
975
976/**
977 * 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