Installation
npm install --save @types/micro-cors
Summary
This package contains type definitions for micro-cors (https://github.com/possibilities/micro-cors#readme).
Details
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/micro-cors.
index.d.ts
import { RequestHandler } from "micro";
interface Options {
maxAge?: number | undefined;
origin?: string | undefined;
allowHeaders?: string[] | undefined;
allowMethods?: string[] | undefined;
exposeHeaders?: string[] | undefined;
allowCredentials?: boolean | undefined;
}
declare function micro_cors(options?: Options): (handler: RequestHandler) => RequestHandler;
export = micro_cors;
Additional Details
- Last updated: Tue, 07 Nov 2023 09:09:39 GMT
- Dependencies: @types/micro
Credits
These definitions were written by Callum Denby, and ChanYong Moon.