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

Function makeMapId

packages/infra/src/Store/Cosmos.ts:24–27  ·  view source on GitHub ↗
(idKey: IdKey)

Source from the content-addressed store, hash-verified

22
23const makeMapId =
24 <IdKey extends keyof Encoded, Encoded extends FieldValues>(idKey: IdKey) => ({ [idKey]: id, ...e }: Encoded) => ({
25 ...e,
26 id
27 })
28const makeReverseMapId =
29 <IdKey extends keyof Encoded, Encoded extends FieldValues>(idKey: IdKey) =>
30 ({ id, ...t }: PersistenceModelType<Omit<Encoded, IdKey> & { id: string }>) =>

Callers 1

Cosmos.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…