@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.
@@ -1,4 +1,4 @@
1
- import { t as __name } from "./chunk-cy2TeOE5.cjs";
1
+ import { t as __name } from "./chunk-DKWOrOAv.js";
2
2
  import { FabricReactNode } from "@kubb/react-fabric/types";
3
3
  import { Operation } from "@kubb/oas";
4
4
 
@@ -1,11 +1,11 @@
1
- import { t as __name } from "./chunk-cy2TeOE5.cjs";
2
- import { n as PluginMsw } from "./types-BvqplGx0.js";
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-cy2TeOE5.cjs";
2
- import { n as PluginMsw, t as Options } from "./types-BvqplGx0.js";
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.0",
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.2",
80
- "@kubb/core": "4.31.0",
81
- "@kubb/oas": "4.31.0",
82
- "@kubb/plugin-faker": "4.31.0",
83
- "@kubb/plugin-oas": "4.31.0",
84
- "@kubb/plugin-ts": "4.31.0"
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": {
@@ -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