(
itemType: ItemType,
schema: S.Codec<T, Encoded, RSchema>,
options: Omit<RepositoryOptions<IdKey, Encoded, T, ItemType, Evt, RPublish, E, RInitial, RCtx, RSchema>, "idKey"> & {
idKey?: IdKey
}
)
| 111 | Evt = never, |
| 112 | RInitial = never, |
| 113 | RPublish = never, |
| 114 | RCtx = never |
| 115 | >( |
| 116 | itemType: ItemType, |
| 117 | schema: S.Codec<T, Encoded, RSchema>, |
| 118 | options: Omit<RepositoryOptions<"id", Encoded, T, ItemType, Evt, RPublish, E, RInitial, RCtx, RSchema>, "idKey"> |
| 119 | ): Effect.Effect< |
| 120 | ExtendedRepository<T, Encoded, Evt, ItemType, "id", Exclude<RSchema, RCtx>, RPublish, RCtx>, |
| 121 | E, |
| 122 | RInitial | StoreMaker | RepositoryRegistry | Scope.Scope |
| 123 | > |
| 124 | } = < |
| 125 | ItemType extends string, |
| 126 | RSchema, |
| 127 | Encoded extends FieldValues, |
| 128 | T, |
| 129 | IdKey extends keyof T & keyof Encoded, |
| 130 | E = never, |
| 131 | RInitial = never, |
| 132 | RPublish = never, |
| 133 | Evt = never, |
| 134 | RCtx = never |
| 135 | >( |
| 136 | itemType: ItemType, |
| 137 | schema: S.Codec<T, Encoded, RSchema>, |
| 138 | options: Omit<RepositoryOptions<IdKey, Encoded, T, ItemType, Evt, RPublish, E, RInitial, RCtx, RSchema>, "idKey"> & { |
| 139 | idKey?: IdKey |
| 140 | } |
| 141 | ) => |
| 142 | Effect.gen(function*() { |
| 143 | const mkRepo = makeRepoInternal<Evt>()( |
| 144 | itemType, |
| 145 | schema, |
| 146 | options?.jitM ? (pm) => options.jitM!(pm) : (pm) => pm, |
| 147 | (e, _etag) => ({ ...e, _etag }), |
| 148 | options.idKey ?? "id" as any |
no test coverage detected
searching dependent graphs…