@kubb/plugin-oas 3.0.0-beta.2 → 3.0.0-beta.4
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/{OperationGenerator-BgQeGRzk.d.cts → OperationGenerator-FtfBxMWU.d.cts} +4 -3
- package/dist/{OperationGenerator-BgQeGRzk.d.ts → OperationGenerator-FtfBxMWU.d.ts} +4 -3
- package/dist/{Schema-1iM2I0dK.d.ts → Schema-T1N1zEsb.d.ts} +1 -1
- package/dist/{Schema-5o-c5UOy.d.cts → Schema-Vr3DsF-v.d.cts} +1 -1
- package/dist/components.d.cts +2 -2
- package/dist/components.d.ts +2 -2
- package/dist/generators.d.cts +1 -1
- package/dist/generators.d.ts +1 -1
- package/dist/hooks.d.cts +2 -2
- package/dist/hooks.d.ts +2 -2
- package/dist/index.d.cts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/utils.d.cts +2 -2
- package/dist/utils.d.ts +2 -2
- package/package.json +8 -8
- package/src/types.ts +4 -4
|
@@ -277,7 +277,8 @@ type Options = {
|
|
|
277
277
|
*/
|
|
278
278
|
validate?: boolean;
|
|
279
279
|
/**
|
|
280
|
-
*
|
|
280
|
+
* Specify the export location for the files and define the behavior of the output
|
|
281
|
+
* @default { path: 'schemas', barrelType: 'named' }
|
|
281
282
|
*/
|
|
282
283
|
output?: Output;
|
|
283
284
|
/**
|
|
@@ -290,7 +291,7 @@ type Options = {
|
|
|
290
291
|
serverIndex?: number;
|
|
291
292
|
/**
|
|
292
293
|
* Define which contentType should be used.
|
|
293
|
-
* By default, this is set based on the
|
|
294
|
+
* By default, this is set based on the contentType being found.
|
|
294
295
|
*/
|
|
295
296
|
contentType?: contentType;
|
|
296
297
|
/**
|
|
@@ -304,7 +305,7 @@ type Options = {
|
|
|
304
305
|
};
|
|
305
306
|
/**
|
|
306
307
|
* `propertyName` is the ref name + resolved with the nameResolver
|
|
307
|
-
* @example
|
|
308
|
+
* @example import { Pet } from './Pet'
|
|
308
309
|
*
|
|
309
310
|
* `originalName` is the original name used(in PascalCase), only used to remove duplicates
|
|
310
311
|
*
|
|
@@ -277,7 +277,8 @@ type Options = {
|
|
|
277
277
|
*/
|
|
278
278
|
validate?: boolean;
|
|
279
279
|
/**
|
|
280
|
-
*
|
|
280
|
+
* Specify the export location for the files and define the behavior of the output
|
|
281
|
+
* @default { path: 'schemas', barrelType: 'named' }
|
|
281
282
|
*/
|
|
282
283
|
output?: Output;
|
|
283
284
|
/**
|
|
@@ -290,7 +291,7 @@ type Options = {
|
|
|
290
291
|
serverIndex?: number;
|
|
291
292
|
/**
|
|
292
293
|
* Define which contentType should be used.
|
|
293
|
-
* By default, this is set based on the
|
|
294
|
+
* By default, this is set based on the contentType being found.
|
|
294
295
|
*/
|
|
295
296
|
contentType?: contentType;
|
|
296
297
|
/**
|
|
@@ -304,7 +305,7 @@ type Options = {
|
|
|
304
305
|
};
|
|
305
306
|
/**
|
|
306
307
|
* `propertyName` is the ref name + resolved with the nameResolver
|
|
307
|
-
* @example
|
|
308
|
+
* @example import { Pet } from './Pet'
|
|
308
309
|
*
|
|
309
310
|
* `originalName` is the original name used(in PascalCase), only used to remove duplicates
|
|
310
311
|
*
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { SchemaObject } from '@kubb/oas';
|
|
3
3
|
import { KubbNode } from '@kubb/react/types';
|
|
4
|
-
import { g as Schema$1 } from './OperationGenerator-
|
|
4
|
+
import { g as Schema$1 } from './OperationGenerator-FtfBxMWU.js';
|
|
5
5
|
|
|
6
6
|
type SchemaContextProps = {
|
|
7
7
|
name: string;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { SchemaObject } from '@kubb/oas';
|
|
3
3
|
import { KubbNode } from '@kubb/react/types';
|
|
4
|
-
import { g as Schema$1 } from './OperationGenerator-
|
|
4
|
+
import { g as Schema$1 } from './OperationGenerator-FtfBxMWU.cjs';
|
|
5
5
|
|
|
6
6
|
type SchemaContextProps = {
|
|
7
7
|
name: string;
|
package/dist/components.d.cts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { S as Schema } from './Schema-
|
|
1
|
+
import { S as Schema } from './Schema-Vr3DsF-v.cjs';
|
|
2
2
|
import * as react from 'react';
|
|
3
3
|
import { Operation as Operation$1, Oas as Oas$1 } from '@kubb/oas';
|
|
4
4
|
import { KubbNode } from '@kubb/react/types';
|
|
5
|
-
import { b as OperationGenerator } from './OperationGenerator-
|
|
5
|
+
import { b as OperationGenerator } from './OperationGenerator-FtfBxMWU.cjs';
|
|
6
6
|
import '@kubb/core';
|
|
7
7
|
import '@kubb/fs/types';
|
|
8
8
|
|
package/dist/components.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { S as Schema } from './Schema-
|
|
1
|
+
import { S as Schema } from './Schema-T1N1zEsb.js';
|
|
2
2
|
import * as react from 'react';
|
|
3
3
|
import { Operation as Operation$1, Oas as Oas$1 } from '@kubb/oas';
|
|
4
4
|
import { KubbNode } from '@kubb/react/types';
|
|
5
|
-
import { b as OperationGenerator } from './OperationGenerator-
|
|
5
|
+
import { b as OperationGenerator } from './OperationGenerator-FtfBxMWU.js';
|
|
6
6
|
import '@kubb/core';
|
|
7
7
|
import '@kubb/fs/types';
|
|
8
8
|
|
package/dist/generators.d.cts
CHANGED
package/dist/generators.d.ts
CHANGED
package/dist/hooks.d.cts
CHANGED
|
@@ -2,8 +2,8 @@ import { Oas, Operation, HttpMethod } from '@kubb/oas';
|
|
|
2
2
|
import { Plugin, ResolveNameParams, FileMetaBase } from '@kubb/core';
|
|
3
3
|
import * as KubbFile from '@kubb/fs/types';
|
|
4
4
|
import { Mode } from '@kubb/fs/types';
|
|
5
|
-
import { w as OperationSchemas, g as Schema } from './OperationGenerator-
|
|
6
|
-
import { a as SchemaContextProps } from './Schema-
|
|
5
|
+
import { w as OperationSchemas, g as Schema } from './OperationGenerator-FtfBxMWU.cjs';
|
|
6
|
+
import { a as SchemaContextProps } from './Schema-Vr3DsF-v.cjs';
|
|
7
7
|
import '@kubb/react/types';
|
|
8
8
|
import 'react';
|
|
9
9
|
|
package/dist/hooks.d.ts
CHANGED
|
@@ -2,8 +2,8 @@ import { Oas, Operation, HttpMethod } from '@kubb/oas';
|
|
|
2
2
|
import { Plugin, ResolveNameParams, FileMetaBase } from '@kubb/core';
|
|
3
3
|
import * as KubbFile from '@kubb/fs/types';
|
|
4
4
|
import { Mode } from '@kubb/fs/types';
|
|
5
|
-
import { w as OperationSchemas, g as Schema } from './OperationGenerator-
|
|
6
|
-
import { a as SchemaContextProps } from './Schema-
|
|
5
|
+
import { w as OperationSchemas, g as Schema } from './OperationGenerator-FtfBxMWU.js';
|
|
6
|
+
import { a as SchemaContextProps } from './Schema-T1N1zEsb.js';
|
|
7
7
|
import '@kubb/react/types';
|
|
8
8
|
import 'react';
|
|
9
9
|
|
package/dist/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as Options, P as PluginOas } from './OperationGenerator-
|
|
2
|
-
export { A as API, E as Exclude, o as Generator, p as GeneratorOptions, G as GetOperationGeneratorOptions, c as GetSchemaGeneratorOptions, I as Include, b as OperationGenerator, a as OperationMethodResult, v as OperationSchema, w as OperationSchemas, x as OperationsByMethod, y as Override, R as ReactGeneratorOptions, r as Ref, t as Refs, q as ResolvePathOptions, u as Resolver, g as Schema, f as SchemaGenerator, S as SchemaGeneratorBuildOptions, d as SchemaGeneratorOptions, h as SchemaKeyword, i as SchemaKeywordBase, j as SchemaKeywordMapper, k as SchemaMapper, e as SchemaMethodResult, m as createGenerator, n as createReactGenerator, l as isKeyword, s as schemaKeywords } from './OperationGenerator-
|
|
1
|
+
import { O as Options, P as PluginOas } from './OperationGenerator-FtfBxMWU.cjs';
|
|
2
|
+
export { A as API, E as Exclude, o as Generator, p as GeneratorOptions, G as GetOperationGeneratorOptions, c as GetSchemaGeneratorOptions, I as Include, b as OperationGenerator, a as OperationMethodResult, v as OperationSchema, w as OperationSchemas, x as OperationsByMethod, y as Override, R as ReactGeneratorOptions, r as Ref, t as Refs, q as ResolvePathOptions, u as Resolver, g as Schema, f as SchemaGenerator, S as SchemaGeneratorBuildOptions, d as SchemaGeneratorOptions, h as SchemaKeyword, i as SchemaKeywordBase, j as SchemaKeywordMapper, k as SchemaMapper, e as SchemaMethodResult, m as createGenerator, n as createReactGenerator, l as isKeyword, s as schemaKeywords } from './OperationGenerator-FtfBxMWU.cjs';
|
|
3
3
|
import * as _kubb_core from '@kubb/core';
|
|
4
4
|
import '@kubb/fs/types';
|
|
5
5
|
import '@kubb/oas';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { O as Options, P as PluginOas } from './OperationGenerator-
|
|
2
|
-
export { A as API, E as Exclude, o as Generator, p as GeneratorOptions, G as GetOperationGeneratorOptions, c as GetSchemaGeneratorOptions, I as Include, b as OperationGenerator, a as OperationMethodResult, v as OperationSchema, w as OperationSchemas, x as OperationsByMethod, y as Override, R as ReactGeneratorOptions, r as Ref, t as Refs, q as ResolvePathOptions, u as Resolver, g as Schema, f as SchemaGenerator, S as SchemaGeneratorBuildOptions, d as SchemaGeneratorOptions, h as SchemaKeyword, i as SchemaKeywordBase, j as SchemaKeywordMapper, k as SchemaMapper, e as SchemaMethodResult, m as createGenerator, n as createReactGenerator, l as isKeyword, s as schemaKeywords } from './OperationGenerator-
|
|
1
|
+
import { O as Options, P as PluginOas } from './OperationGenerator-FtfBxMWU.js';
|
|
2
|
+
export { A as API, E as Exclude, o as Generator, p as GeneratorOptions, G as GetOperationGeneratorOptions, c as GetSchemaGeneratorOptions, I as Include, b as OperationGenerator, a as OperationMethodResult, v as OperationSchema, w as OperationSchemas, x as OperationsByMethod, y as Override, R as ReactGeneratorOptions, r as Ref, t as Refs, q as ResolvePathOptions, u as Resolver, g as Schema, f as SchemaGenerator, S as SchemaGeneratorBuildOptions, d as SchemaGeneratorOptions, h as SchemaKeyword, i as SchemaKeywordBase, j as SchemaKeywordMapper, k as SchemaMapper, e as SchemaMethodResult, m as createGenerator, n as createReactGenerator, l as isKeyword, s as schemaKeywords } from './OperationGenerator-FtfBxMWU.js';
|
|
3
3
|
import * as _kubb_core from '@kubb/core';
|
|
4
4
|
import '@kubb/fs/types';
|
|
5
5
|
import '@kubb/oas';
|
package/dist/utils.d.cts
CHANGED
|
@@ -2,8 +2,8 @@ import { Operation, Oas, SchemaObject, OpenAPIV3, OpenAPIV3_1 } from '@kubb/oas'
|
|
|
2
2
|
export { isOptional } from '@kubb/oas';
|
|
3
3
|
import { FunctionParamsAST } from '@kubb/core/utils';
|
|
4
4
|
import { Params } from '@kubb/react/types';
|
|
5
|
-
import { v as OperationSchema } from './OperationGenerator-
|
|
6
|
-
export { z as GetSchemasProps, B as getSchemas } from './OperationGenerator-
|
|
5
|
+
import { v as OperationSchema } from './OperationGenerator-FtfBxMWU.cjs';
|
|
6
|
+
export { z as GetSchemasProps, B as getSchemas } from './OperationGenerator-FtfBxMWU.cjs';
|
|
7
7
|
import { Config } from '@kubb/core';
|
|
8
8
|
import '@kubb/fs/types';
|
|
9
9
|
|
package/dist/utils.d.ts
CHANGED
|
@@ -2,8 +2,8 @@ import { Operation, Oas, SchemaObject, OpenAPIV3, OpenAPIV3_1 } from '@kubb/oas'
|
|
|
2
2
|
export { isOptional } from '@kubb/oas';
|
|
3
3
|
import { FunctionParamsAST } from '@kubb/core/utils';
|
|
4
4
|
import { Params } from '@kubb/react/types';
|
|
5
|
-
import { v as OperationSchema } from './OperationGenerator-
|
|
6
|
-
export { z as GetSchemasProps, B as getSchemas } from './OperationGenerator-
|
|
5
|
+
import { v as OperationSchema } from './OperationGenerator-FtfBxMWU.js';
|
|
6
|
+
export { z as GetSchemasProps, B as getSchemas } from './OperationGenerator-FtfBxMWU.js';
|
|
7
7
|
import { Config } from '@kubb/core';
|
|
8
8
|
import '@kubb/fs/types';
|
|
9
9
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kubb/plugin-oas",
|
|
3
|
-
"version": "3.0.0-beta.
|
|
3
|
+
"version": "3.0.0-beta.4",
|
|
4
4
|
"description": "Generator swagger",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"typescript",
|
|
@@ -76,21 +76,21 @@
|
|
|
76
76
|
"dependencies": {
|
|
77
77
|
"@stoplight/yaml": "^4.3.0",
|
|
78
78
|
"remeda": "^2.14.0",
|
|
79
|
-
"@kubb/core": "3.0.0-beta.
|
|
80
|
-
"@kubb/fs": "3.0.0-beta.
|
|
81
|
-
"@kubb/oas": "3.0.0-beta.
|
|
82
|
-
"@kubb/react": "3.0.0-beta.
|
|
79
|
+
"@kubb/core": "3.0.0-beta.4",
|
|
80
|
+
"@kubb/fs": "3.0.0-beta.4",
|
|
81
|
+
"@kubb/oas": "3.0.0-beta.4",
|
|
82
|
+
"@kubb/react": "3.0.0-beta.4"
|
|
83
83
|
},
|
|
84
84
|
"devDependencies": {
|
|
85
85
|
"@types/react": "^18.3.11",
|
|
86
86
|
"react": "^18.3.1",
|
|
87
87
|
"tsup": "^8.3.0",
|
|
88
88
|
"typescript": "^5.6.2",
|
|
89
|
-
"@kubb/config-ts": "3.0.0-beta.
|
|
90
|
-
"@kubb/config-tsup": "3.0.0-beta.
|
|
89
|
+
"@kubb/config-ts": "3.0.0-beta.4",
|
|
90
|
+
"@kubb/config-tsup": "3.0.0-beta.4"
|
|
91
91
|
},
|
|
92
92
|
"peerDependencies": {
|
|
93
|
-
"@kubb/react": "3.0.0-beta.
|
|
93
|
+
"@kubb/react": "3.0.0-beta.4"
|
|
94
94
|
},
|
|
95
95
|
"engines": {
|
|
96
96
|
"node": ">=20"
|
package/src/types.ts
CHANGED
|
@@ -26,7 +26,8 @@ export type Options = {
|
|
|
26
26
|
*/
|
|
27
27
|
validate?: boolean
|
|
28
28
|
/**
|
|
29
|
-
*
|
|
29
|
+
* Specify the export location for the files and define the behavior of the output
|
|
30
|
+
* @default { path: 'schemas', barrelType: 'named' }
|
|
30
31
|
*/
|
|
31
32
|
output?: Output
|
|
32
33
|
/**
|
|
@@ -39,7 +40,7 @@ export type Options = {
|
|
|
39
40
|
serverIndex?: number
|
|
40
41
|
/**
|
|
41
42
|
* Define which contentType should be used.
|
|
42
|
-
* By default, this is set based on the
|
|
43
|
+
* By default, this is set based on the contentType being found.
|
|
43
44
|
*/
|
|
44
45
|
contentType?: contentType
|
|
45
46
|
/**
|
|
@@ -54,14 +55,13 @@ export type Options = {
|
|
|
54
55
|
|
|
55
56
|
/**
|
|
56
57
|
* `propertyName` is the ref name + resolved with the nameResolver
|
|
57
|
-
* @example
|
|
58
|
+
* @example import { Pet } from './Pet'
|
|
58
59
|
*
|
|
59
60
|
* `originalName` is the original name used(in PascalCase), only used to remove duplicates
|
|
60
61
|
*
|
|
61
62
|
* `pluginKey` can be used to override the current plugin being used, handy when you want to import a type/schema out of another plugin
|
|
62
63
|
* @example import a type(plugin-ts) for a mock file(swagger-faker)
|
|
63
64
|
*/
|
|
64
|
-
|
|
65
65
|
export type Ref = {
|
|
66
66
|
propertyName: string
|
|
67
67
|
originalName: string
|