@kubb/core 1.15.0-canary.20231027T173208 → 1.15.0-canary.20231027T185539
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/index.cjs +1025 -1163
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +313 -255
- package/dist/index.d.ts +313 -255
- package/dist/index.js +948 -1095
- package/dist/index.js.map +1 -1
- package/globals.d.ts +16 -33
- package/package.json +10 -15
- package/dist/utils.cjs +0 -1260
- package/dist/utils.cjs.map +0 -1
- package/dist/utils.d.cts +0 -235
- package/dist/utils.d.ts +0 -235
- package/dist/utils.js +0 -1207
- package/dist/utils.js.map +0 -1
package/globals.d.ts
CHANGED
|
@@ -1,6 +1,17 @@
|
|
|
1
1
|
/// <reference no-default-lib="true" />
|
|
2
2
|
/// <reference lib="esnext" />
|
|
3
3
|
|
|
4
|
+
type KubbObjectPlugins = {
|
|
5
|
+
['@kubb/swagger']: import('@kubb/swagger').PluginOptions
|
|
6
|
+
['@kubb/swagger-client']: import('@kubb/swagger-client').PluginOptions
|
|
7
|
+
['@kubb/swagger-faker']: import('@kubb/swagger-faker').PluginOptions
|
|
8
|
+
['@kubb/swagger-swr']: import('@kubb/swagger-swr').PluginOptions
|
|
9
|
+
['@kubb/swagger-tanstack-query']: import('@kubb/swagger-tanstack-query').PluginOptions
|
|
10
|
+
['@kubb/swagger-ts']: import('@kubb/swagger-ts').PluginOptions
|
|
11
|
+
['@kubb/swagger-zod']: import('@kubb/swagger-zod').PluginOptions
|
|
12
|
+
['@kubb/swagger-zodios']: import('@kubb/swagger-zodios').PluginOptions
|
|
13
|
+
['@kubb/swagger-msw']: import('@kubb/swagger-msw').PluginOptions
|
|
14
|
+
}
|
|
4
15
|
/**
|
|
5
16
|
* `tsconfig.json`
|
|
6
17
|
* @example
|
|
@@ -13,39 +24,11 @@ const swaggerPlugin: SwaggerPlugin={
|
|
|
13
24
|
___ validate: true
|
|
14
25
|
}
|
|
15
26
|
*/
|
|
16
|
-
declare
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
type LastOf<T> = UnionToIntersection<T extends any ? () => T : never> extends () => infer R ? R : never
|
|
20
|
-
|
|
21
|
-
// TS4.0+
|
|
22
|
-
type Push<T extends any[], V> = [...T, V]
|
|
23
|
-
|
|
24
|
-
// TS4.1+
|
|
25
|
-
type TuplifyUnion<T, L = LastOf<T>, N = [T] extends [never] ? true : false> = true extends N ? [] : Push<TuplifyUnion<Exclude<T, L>>, L>
|
|
26
|
-
|
|
27
|
-
type ObjValueTuple<T, KS extends any[] = TuplifyUnion<keyof T>, R extends any[] = []> = KS extends [infer K, ...infer KT]
|
|
28
|
-
? ObjValueTuple<T, KT, [...R, [name: K & keyof T, options: T[K & keyof T]]]>
|
|
29
|
-
: R
|
|
30
|
-
|
|
31
|
-
type TupleToUnion<T> = T extends Array<infer ITEMS> ? ITEMS : never
|
|
32
|
-
}
|
|
33
|
-
type Plugins = {
|
|
34
|
-
['@kubb/swagger']: import('@kubb/swagger').PluginOptions
|
|
35
|
-
['@kubb/swagger-client']: import('@kubb/swagger-client').PluginOptions
|
|
36
|
-
['@kubb/swagger-faker']: import('@kubb/swagger-faker').PluginOptions
|
|
37
|
-
['@kubb/swagger-swr']: import('@kubb/swagger-swr').PluginOptions
|
|
38
|
-
['@kubb/swagger-tanstack-query']: import('@kubb/swagger-tanstack-query').PluginOptions
|
|
39
|
-
['@kubb/swagger-ts']: import('@kubb/swagger-ts').PluginOptions
|
|
40
|
-
['@kubb/swagger-zod']: import('@kubb/swagger-zod').PluginOptions
|
|
41
|
-
['@kubb/swagger-zodios']: import('@kubb/swagger-zodios').PluginOptions
|
|
42
|
-
['@kubb/swagger-msw']: import('@kubb/swagger-msw').PluginOptions
|
|
43
|
-
}
|
|
44
|
-
type OptionsPlugins = { [K in keyof Plugins]: Plugins[K]['options'] }
|
|
45
|
-
|
|
46
|
-
type OptionsOfPlugin<K extends keyof Plugins> = Plugins[K]['options']
|
|
27
|
+
declare module Kubb {
|
|
28
|
+
type Plugins = _Register
|
|
29
|
+
type OptionsPlugins = { [K in keyof KubbObjectPlugins]: KubbObjectPlugins[K]['options'] }
|
|
47
30
|
|
|
48
|
-
type
|
|
31
|
+
type OptionsOfPlugin<K extends keyof KubbObjectPlugins> = KubbObjectPlugins[K]['options']
|
|
49
32
|
|
|
50
|
-
type Plugin = keyof
|
|
33
|
+
type Plugin = keyof KubbObjectPlugins
|
|
51
34
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kubb/core",
|
|
3
|
-
"version": "1.15.0-canary.
|
|
3
|
+
"version": "1.15.0-canary.20231027T185539",
|
|
4
4
|
"description": "Generator core",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"typescript",
|
|
@@ -23,11 +23,6 @@
|
|
|
23
23
|
"require": "./dist/index.cjs",
|
|
24
24
|
"default": "./dist/index.cjs"
|
|
25
25
|
},
|
|
26
|
-
"./utils": {
|
|
27
|
-
"import": "./dist/utils.js",
|
|
28
|
-
"require": "./dist/utils.cjs",
|
|
29
|
-
"default": "./dist/utils.cjs"
|
|
30
|
-
},
|
|
31
26
|
"./package.json": "./package.json",
|
|
32
27
|
"./*": "./*",
|
|
33
28
|
"./globals": {
|
|
@@ -46,7 +41,6 @@
|
|
|
46
41
|
"!/**/__tests__/**"
|
|
47
42
|
],
|
|
48
43
|
"dependencies": {
|
|
49
|
-
"@kubb/parser": "true",
|
|
50
44
|
"change-case": "^4.1.2",
|
|
51
45
|
"directory-tree": "^3.5.1",
|
|
52
46
|
"find-up": "^6.3.0",
|
|
@@ -56,21 +50,22 @@
|
|
|
56
50
|
"natural-orderby": "^3.0.2",
|
|
57
51
|
"picocolors": "^1.0.0",
|
|
58
52
|
"seedrandom": "^3.0.5",
|
|
59
|
-
"semver": "^7.5.4"
|
|
53
|
+
"semver": "^7.5.4",
|
|
54
|
+
"@kubb/parser": "1.15.0-canary.20231027T185523"
|
|
60
55
|
},
|
|
61
56
|
"devDependencies": {
|
|
62
|
-
"@kubb/eslint-config": "true",
|
|
63
|
-
"@kubb/ts-config": "true",
|
|
64
|
-
"@kubb/tsup-config": "true",
|
|
65
57
|
"@types/fs-extra": "^11.0.3",
|
|
66
58
|
"@types/lodash.isequal": "4.5.6",
|
|
67
|
-
"@types/react": "^18.2.
|
|
59
|
+
"@types/react": "^18.2.31",
|
|
68
60
|
"@types/seedrandom": "^3.0.7",
|
|
69
61
|
"@types/semver": "^7.5.4",
|
|
70
62
|
"eslint": "^8.52.0",
|
|
71
63
|
"ora": "^7.0.1",
|
|
72
64
|
"tsup": "^7.2.0",
|
|
73
|
-
"typescript": "^5.2.2"
|
|
65
|
+
"typescript": "^5.2.2",
|
|
66
|
+
"@kubb/eslint-config": "1.1.8",
|
|
67
|
+
"@kubb/ts-config": "0.1.0",
|
|
68
|
+
"@kubb/tsup-config": "1.1.8"
|
|
74
69
|
},
|
|
75
70
|
"packageManager": "pnpm@8.3.0",
|
|
76
71
|
"engines": {
|
|
@@ -87,8 +82,8 @@
|
|
|
87
82
|
"lint": "ESLINT_USE_FLAT_CONFIG=true eslint --format pretty .",
|
|
88
83
|
"lint-fix": "bun run lint --quiet --fix",
|
|
89
84
|
"release": "pnpm publish --no-git-check",
|
|
90
|
-
"release:canary": "bash ../../.github/canary.sh &&
|
|
91
|
-
"release:alpha": "bash ../../.github/canary.sh &&
|
|
85
|
+
"release:canary": "bash ../../.github/canary.sh && pnpm publish --no-git-check -tag canary",
|
|
86
|
+
"release:alpha": "bash ../../.github/canary.sh && pnpm publish --no-git-check -tag alpha",
|
|
92
87
|
"start": "tsup --watch",
|
|
93
88
|
"test": "vitest --passWithNoTests",
|
|
94
89
|
"typecheck": "tsc -p ./tsconfig.json --noEmit --emitDeclarationOnly false"
|