We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c1e35e4 commit f15c661Copy full SHA for f15c661
packages/vite-plugin-mock/src/types.ts
@@ -24,10 +24,12 @@ export declare interface MockMethod {
24
method?: MethodType
25
timeout?: number
26
statusCode?: number
27
- response?: (
28
- this: RespThisType,
29
- opt: { url: Recordable; body: Recordable; query: Recordable; headers: Recordable },
30
- ) => any
+ response?:
+ | ((
+ this: RespThisType,
+ opt: { url: Recordable; body: Recordable; query: Recordable; headers: Recordable },
31
+ ) => any)
32
+ | any
33
rawResponse?: (this: RespThisType, req: IncomingMessage, res: ServerResponse) => void
34
}
35
0 commit comments