MCPcopy
hub / github.com/Effect-TS/effect / retrieve

Function retrieve

packages/effect/test/ScopedCache.test.ts:622–626  ·  view source on GitHub ↗
(multiplier: Ref.Ref<number>)

Source from the content-addressed store, hash-verified

620 Effect.gen(function*() {
621 const inc = (n: number) => n * 10
622 const retrieve = (multiplier: Ref.Ref<number>) => (key: number) =>
623 pipe(
624 Ref.updateAndGet(multiplier, inc),
625 Effect.map((multiplier) => key * multiplier)
626 )
627 const seed = 1
628 const key = 123
629 const ref = yield* (Ref.make(seed))

Callers 1

Calls 3

pipeFunction · 0.90
mapMethod · 0.65
failMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…