itty-router
Advanced tools
Comparing version 4.3.0-next.3 to 4.3.0-next.4
@@ -0,1 +1,2 @@ | ||
import { IRequest } from 'IttyRouter'; | ||
export type CorsOptions = { | ||
@@ -9,2 +10,8 @@ credentials?: true; | ||
}; | ||
export type Preflight = (request: IRequest) => Response | void; | ||
export type Corsify = (response: Response, request?: IRequest) => Response; | ||
export type CorsPair = { | ||
preflight: Preflight; | ||
corsify: Corsify; | ||
}; | ||
export declare const cors: (options?: CorsOptions) => { | ||
@@ -11,0 +18,0 @@ corsify: (response: Response, request?: Request) => Response; |
{ | ||
"name": "itty-router", | ||
"version": "4.3.0-next.3", | ||
"version": "4.3.0-next.4", | ||
"description": "A tiny, zero-dependency router, designed to make beautiful APIs in any environment.", | ||
@@ -5,0 +5,0 @@ "main": "./index.js", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
81605
292