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

Function layer

packages/sql-libsql/src/LibsqlClient.ts:318–326  ·  view source on GitHub ↗
(
  config: LibsqlClientConfig
)

Source from the content-addressed store, hash-verified

316 * @since 1.0.0
317 */
318export const layer = (
319 config: LibsqlClientConfig
320): Layer.Layer<LibsqlClient | Client.SqlClient> =>
321 Layer.scopedContext(
322 Effect.map(make(config), (client) =>
323 Context.make(LibsqlClient, client).pipe(
324 Context.add(Client.SqlClient, client)
325 ))
326 ).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