(corsOptions?: CorsOptions)
| 119 | export const context = Context.makeUnsafe<unknown>(new Map()) |
| 120 | |
| 121 | const cors = (corsOptions?: CorsOptions) => |
| 122 | HttpRouter.middleware( |
| 123 | HttpMiddleware.cors({ |
| 124 | allowedOrigins: (origin) => isAllowedCorsOrigin(origin, corsOptions), |
| 125 | maxAge: 86_400, |
| 126 | }), |
| 127 | { global: true }, |
| 128 | ) |
| 129 | |
| 130 | // Route tree: |
| 131 | // - rootApiRoutes: typed /global/* and control routes; auth is declared by RootHttpApi. |
no test coverage detected