MCPcopy Create free account
hub / github.com/tinyhttp/tinyhttp / all

Method all

packages/router/src/index.ts:232–243  ·  view source on GitHub ↗
(...args: RouterMethodParams<Req, Res>)

Source from the content-addressed store, hash-verified

230 }
231
232 all(...args: RouterMethodParams<Req, Res>) {
233 const handlers = args.slice(1).flat() as Handler<Req, Res>[]
234
235 pushMiddleware(this.middleware)({
236 path: args[0],
237 handler: handlers[0],
238 handlers: handlers.slice(1),
239 type: 'route'
240 })
241
242 return this
243 }
244
245 /**
246 * Return the app's absolute pathname

Callers 3

server.jsFile · 0.45
router.test.tsFile · 0.45
app.test.tsFile · 0.45

Calls 1

pushMiddlewareFunction · 0.85

Tested by

no test coverage detected