MCPcopy Index your code
hub / github.com/Effect-TS/effect / layer

Function layer

packages/sql-sqlite-node/src/SqliteClient.ts:276–284  ·  view source on GitHub ↗
(
  config: SqliteClientConfig
)

Source from the content-addressed store, hash-verified

274 * @since 1.0.0
275 */
276export const layer = (
277 config: SqliteClientConfig
278): Layer.Layer<SqliteClient | Client.SqlClient, ConfigError> =>
279 Layer.scopedContext(
280 Effect.map(make(config), (client) =>
281 Context.make(SqliteClient, client).pipe(
282 Context.add(Client.SqlClient, client)
283 ))
284 ).pipe(Layer.provide(Reactivity.layer))

Callers

nothing calls this directly

Calls 6

makeFunction · 0.70
pipeMethod · 0.65
mapMethod · 0.65
makeMethod · 0.65
addMethod · 0.65
provideMethod · 0.65

Tested by

no test coverage detected