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

Function schemaPathParams

packages/platform/src/internal/httpRouter.ts:136–142  ·  view source on GitHub ↗
(
  schema: Schema.Schema<A, I, R>,
  options?: ParseOptions | undefined
)

Source from the content-addressed store, hash-verified

134
135/** @internal */
136export const schemaPathParams = <A, I extends Readonly<Record<string, string | undefined>>, R>(
137 schema: Schema.Schema<A, I, R>,
138 options?: ParseOptions | undefined
139) => {
140 const parse = Schema.decodeUnknown(schema, options)
141 return Effect.flatMap(RouteContext, (_) => parse(_.params))
142}
143
144/** @internal */
145export const currentRouterConfig = globalValue(

Callers

nothing calls this directly

Calls 1

parseFunction · 0.70

Tested by

no test coverage detected