@kubb/plugin-msw 4.31.0 → 4.31.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components.d.ts +1 -1
- package/dist/generators.d.ts +5 -5
- package/dist/index.d.ts +2 -2
- package/package.json +7 -7
- package/dist/types-BvqplGx0.d.ts +0 -68
package/dist/components.d.ts
CHANGED
package/dist/generators.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { t as __name } from "./chunk-
|
|
2
|
-
import { n as PluginMsw } from "./types-
|
|
3
|
-
import { FabricReactNode } from "@kubb/react-fabric/types";
|
|
4
|
-
import { HttpMethod, Oas, Operation, SchemaObject, contentType } from "@kubb/oas";
|
|
1
|
+
import { t as __name } from "./chunk-DKWOrOAv.js";
|
|
2
|
+
import { n as PluginMsw } from "./types-DUwv-QOP.js";
|
|
5
3
|
import { BaseGenerator, Config, FileMetaBase, Group, KubbEvents, Output, Plugin, PluginFactoryOptions, PluginManager, ResolveNameParams } from "@kubb/core";
|
|
4
|
+
import { Fabric } from "@kubb/react-fabric";
|
|
6
5
|
import { AsyncEventEmitter } from "@kubb/core/utils";
|
|
6
|
+
import { FabricReactNode } from "@kubb/react-fabric/types";
|
|
7
|
+
import { HttpMethod, Oas, Operation, SchemaObject, contentType } from "@kubb/oas";
|
|
7
8
|
import { KubbFile } from "@kubb/fabric-core/types";
|
|
8
|
-
import { Fabric } from "@kubb/react-fabric";
|
|
9
9
|
|
|
10
10
|
//#region ../plugin-oas/src/types.d.ts
|
|
11
11
|
type GetOasOptions = {
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { t as __name } from "./chunk-
|
|
2
|
-
import { n as PluginMsw, t as Options } from "./types-
|
|
1
|
+
import { t as __name } from "./chunk-DKWOrOAv.js";
|
|
2
|
+
import { n as PluginMsw, t as Options } from "./types-DUwv-QOP.js";
|
|
3
3
|
import * as _kubb_core0 from "@kubb/core";
|
|
4
4
|
|
|
5
5
|
//#region src/plugin.d.ts
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kubb/plugin-msw",
|
|
3
|
-
"version": "4.31.
|
|
3
|
+
"version": "4.31.1",
|
|
4
4
|
"description": "Mock Service Worker (MSW) handlers generator plugin for Kubb, creating API mocks from OpenAPI specifications for frontend development and testing.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"msw",
|
|
@@ -76,12 +76,12 @@
|
|
|
76
76
|
}
|
|
77
77
|
],
|
|
78
78
|
"dependencies": {
|
|
79
|
-
"@kubb/react-fabric": "0.13.
|
|
80
|
-
"@kubb/core": "4.31.
|
|
81
|
-
"@kubb/oas": "4.31.
|
|
82
|
-
"@kubb/plugin-faker": "4.31.
|
|
83
|
-
"@kubb/plugin-oas": "4.31.
|
|
84
|
-
"@kubb/plugin-ts": "4.31.
|
|
79
|
+
"@kubb/react-fabric": "0.13.3",
|
|
80
|
+
"@kubb/core": "4.31.1",
|
|
81
|
+
"@kubb/oas": "4.31.1",
|
|
82
|
+
"@kubb/plugin-faker": "4.31.1",
|
|
83
|
+
"@kubb/plugin-oas": "4.31.1",
|
|
84
|
+
"@kubb/plugin-ts": "4.31.1"
|
|
85
85
|
},
|
|
86
86
|
"devDependencies": {},
|
|
87
87
|
"engines": {
|
package/dist/types-BvqplGx0.d.ts
DELETED
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
import { t as __name } from "./chunk-cy2TeOE5.cjs";
|
|
2
|
-
import { Oas, contentType } from "@kubb/oas";
|
|
3
|
-
import { Group, Output, PluginFactoryOptions, ResolveNameParams } from "@kubb/core";
|
|
4
|
-
import { Exclude, Include, Override, ResolvePathOptions } from "@kubb/plugin-oas";
|
|
5
|
-
import { Generator } from "@kubb/plugin-oas/generators";
|
|
6
|
-
|
|
7
|
-
//#region src/types.d.ts
|
|
8
|
-
type Options = {
|
|
9
|
-
/**
|
|
10
|
-
* Specify the export location for the files and define the behavior of the output
|
|
11
|
-
* @default { path: 'mocks', barrelType: 'named' }
|
|
12
|
-
*/
|
|
13
|
-
output?: Output<Oas>;
|
|
14
|
-
/**
|
|
15
|
-
* Define which contentType should be used.
|
|
16
|
-
* By default, the first JSON valid mediaType is used
|
|
17
|
-
*/
|
|
18
|
-
contentType?: contentType;
|
|
19
|
-
baseURL?: string;
|
|
20
|
-
/**
|
|
21
|
-
* Group the MSW mocks based on the provided name.
|
|
22
|
-
*/
|
|
23
|
-
group?: Group;
|
|
24
|
-
/**
|
|
25
|
-
* Array containing exclude parameters to exclude/skip tags/operations/methods/paths.
|
|
26
|
-
*/
|
|
27
|
-
exclude?: Array<Exclude>;
|
|
28
|
-
/**
|
|
29
|
-
* Array containing include parameters to include tags/operations/methods/paths.
|
|
30
|
-
*/
|
|
31
|
-
include?: Array<Include>;
|
|
32
|
-
/**
|
|
33
|
-
* Array containing override parameters to override `options` based on tags/operations/methods/paths.
|
|
34
|
-
*/
|
|
35
|
-
override?: Array<Override<ResolvedOptions>>;
|
|
36
|
-
transformers?: {
|
|
37
|
-
/**
|
|
38
|
-
* Customize the names based on the type that is provided by the plugin.
|
|
39
|
-
*/
|
|
40
|
-
name?: (name: ResolveNameParams['name'], type?: ResolveNameParams['type']) => string;
|
|
41
|
-
};
|
|
42
|
-
/**
|
|
43
|
-
* Create `handlers.ts` file with all handlers grouped by methods.
|
|
44
|
-
* @default false
|
|
45
|
-
*/
|
|
46
|
-
handlers?: boolean;
|
|
47
|
-
/**
|
|
48
|
-
* Which parser should be used before returning the data to the Response of MSW.
|
|
49
|
-
* - 'data' uses your custom data to generate the data for the response.
|
|
50
|
-
* - 'faker' uses @kubb/plugin-faker to generate the data for the response.
|
|
51
|
-
* @default 'data'
|
|
52
|
-
*/
|
|
53
|
-
parser?: 'data' | 'faker';
|
|
54
|
-
/**
|
|
55
|
-
* Define some generators next to the msw generators
|
|
56
|
-
*/
|
|
57
|
-
generators?: Array<Generator<PluginMsw>>;
|
|
58
|
-
};
|
|
59
|
-
type ResolvedOptions = {
|
|
60
|
-
output: Output<Oas>;
|
|
61
|
-
group: Options['group'];
|
|
62
|
-
parser: NonNullable<Options['parser']>;
|
|
63
|
-
baseURL: Options['baseURL'] | undefined;
|
|
64
|
-
};
|
|
65
|
-
type PluginMsw = PluginFactoryOptions<'plugin-msw', Options, ResolvedOptions, never, ResolvePathOptions>;
|
|
66
|
-
//#endregion
|
|
67
|
-
export { PluginMsw as n, Options as t };
|
|
68
|
-
//# sourceMappingURL=types-BvqplGx0.d.ts.map
|