mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-07-01 15:50:13 +00:00
Merge pull request #15340 from izayoiko/patch-1
kcors: Fix options type
This commit is contained in:
6
kcors/index.d.ts
vendored
6
kcors/index.d.ts
vendored
@@ -1,6 +1,6 @@
|
||||
// Type definitions for kcors 2.2
|
||||
// Project: https://github.com/koajs/cors
|
||||
// Definitions by: Xavier Stouder <https://github.com/Xstoudi>
|
||||
// Definitions by: Xavier Stouder <https://github.com/Xstoudi>, Izayoi Ko <https://github.com/izayoiko>
|
||||
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
||||
|
||||
import * as Koa from "koa";
|
||||
@@ -10,10 +10,10 @@ export = cors;
|
||||
|
||||
declare namespace cors {
|
||||
interface Options {
|
||||
origin?: (req: Koa.Request) => string | string;
|
||||
origin?: ((req: Koa.Request) => string) | string;
|
||||
allowMethods?: string[] | string;
|
||||
exposeHeaders?: string[] | string;
|
||||
allowHeaders: string[] | string;
|
||||
allowHeaders?: string[] | string;
|
||||
maxAge?: number | string;
|
||||
credentials?: boolean;
|
||||
keepHeadersOnError?: boolean;
|
||||
|
||||
Reference in New Issue
Block a user