tool.mts
This file
Path
benchmarks/routers/src/tool.mts
26 lines 路 804 bytes 路 TypeScript
Last changed by
Not known.
History of this fileTake it
123456789101112131415161718192021222324252627export const handler = () => {}
export type Route = { method: 'GET' | 'POST' path: string}
export interface RouterInterface { name: string match: (route: Route) => unknown}
export const routes: Route[] = [ { method: 'GET', path: '/user' }, { method: 'GET', path: '/user/comments' }, { method: 'GET', path: '/user/avatar' }, { method: 'GET', path: '/user/lookup/username/:username' }, { method: 'GET', path: '/user/lookup/email/:address' }, { method: 'GET', path: '/event/:id' }, { method: 'GET', path: '/event/:id/comments' }, { method: 'POST', path: '/event/:id/comment' }, { method: 'GET', path: '/map/:location/events' }, { method: 'GET', path: '/status' }, { method: 'GET', path: '/very/deeply/nested/route/hello/there' }, { method: 'GET', path: '/static/*' },]