MCPcopy Create free account
hub / github.com/effect-app/libs / updateWithEffect

Function updateWithEffect

packages/effect-app/src/Pure.ts:231–235  ·  view source on GitHub ↗
(
  upd: (s: S2, log: (evt: W) => PureLogT<W>) => Effect.Effect<S3, E, FixEnv<R, W, S2, S3>>
)

Source from the content-addressed store, hash-verified

229}
230
231export function updateWithEffect<W, R, E, S2, S3>(
232 upd: (s: S2, log: (evt: W) => PureLogT<W>) => Effect.Effect<S3, E, FixEnv<R, W, S2, S3>>
233): Effect.Effect<S3, E, FixEnv<R, W, S2, S3>> {
234 return modifyM((_: S2) => Effect.map(upd(_, log), (_) => tuple(_, _)))
235}
236
237export type FixEnv<R, W, S, S2> =
238 | Exclude<R, PureEnvEnv<any, any, any>>

Callers

nothing calls this directly

Calls 4

tupleFunction · 0.90
modifyMFunction · 0.85
updFunction · 0.85
mapMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…