MCPcopy
hub / github.com/Effect-TS/effect / concatAll

Function concatAll

packages/platform/src/internal/httpRouter.ts:386–401  ·  view source on GitHub ↗
(
  ...routers: Routers
)

Source from the content-addressed store, hash-verified

384
385/** @internal */
386export const concatAll = <Routers extends ReadonlyArray<Router.HttpRouter<E, R>>, E, R>(
387 ...routers: Routers
388) =>
389 new RouterImpl(
390 routers.reduce((cur, acc) => Chunk.appendAll(cur, acc.routes), Chunk.empty<Router.Route<E, R>>()),
391 routers.reduce(
392 (cur, acc) => Chunk.appendAll(cur, acc.mounts),
393 Chunk.empty<
394 readonly [
395 prefix: string,
396 httpApp: App.Default<E, R>,
397 options?: { readonly includePrefix?: boolean | undefined } | undefined
398 ]
399 >()
400 )
401 ) as any
402
403const removeTrailingSlash = (
404 path: Router.PathInput

Callers 1

httpRouter.tsFile · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected