@genapi/presets 3.0.0
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/LICENSE.md +21 -0
- package/dist/axios/index.d.ts +9 -0
- package/dist/axios/index.mjs +7 -0
- package/dist/axios/js/config/index.d.ts +5 -0
- package/dist/axios/js/config/index.mjs +18 -0
- package/dist/axios/js/index.d.ts +6 -0
- package/dist/axios/js/index.mjs +25 -0
- package/dist/axios/js/parser/index.d.ts +12 -0
- package/dist/axios/js/parser/index.mjs +77 -0
- package/dist/axios/ts/config/index.d.ts +5 -0
- package/dist/axios/ts/config/index.mjs +22 -0
- package/dist/axios/ts/index.d.ts +6 -0
- package/dist/axios/ts/index.mjs +25 -0
- package/dist/axios/ts/parser/index.d.ts +12 -0
- package/dist/axios/ts/parser/index.mjs +76 -0
- package/dist/fetch/index.d.ts +9 -0
- package/dist/fetch/index.mjs +7 -0
- package/dist/fetch/js/config/index.d.ts +5 -0
- package/dist/fetch/js/config/index.mjs +13 -0
- package/dist/fetch/js/index.d.ts +6 -0
- package/dist/fetch/js/index.mjs +25 -0
- package/dist/fetch/js/parser/index.d.ts +12 -0
- package/dist/fetch/js/parser/index.mjs +83 -0
- package/dist/fetch/ts/config/index.d.ts +5 -0
- package/dist/fetch/ts/config/index.mjs +11 -0
- package/dist/fetch/ts/index.d.ts +6 -0
- package/dist/fetch/ts/index.mjs +25 -0
- package/dist/fetch/ts/parser/index.d.ts +12 -0
- package/dist/fetch/ts/parser/index.mjs +79 -0
- package/dist/got/index.d.ts +9 -0
- package/dist/got/index.mjs +7 -0
- package/dist/got/js/config/index.d.ts +5 -0
- package/dist/got/js/config/index.mjs +18 -0
- package/dist/got/js/index.d.ts +6 -0
- package/dist/got/js/index.mjs +25 -0
- package/dist/got/js/parser/index.d.ts +12 -0
- package/dist/got/js/parser/index.mjs +82 -0
- package/dist/got/ts/config/index.d.ts +5 -0
- package/dist/got/ts/config/index.mjs +22 -0
- package/dist/got/ts/index.d.ts +6 -0
- package/dist/got/ts/index.mjs +25 -0
- package/dist/got/ts/parser/index.d.ts +12 -0
- package/dist/got/ts/parser/index.mjs +82 -0
- package/dist/index--xiziIvG.d.ts +8 -0
- package/dist/index-BByL5W2V.d.ts +18 -0
- package/dist/index-BIRCFgYi.d.ts +18 -0
- package/dist/index-BJrp0lx3.d.ts +18 -0
- package/dist/index-BWvY4w5U.d.ts +8 -0
- package/dist/index-BnNpBsOT.d.ts +18 -0
- package/dist/index-CApSnKVf.d.ts +8 -0
- package/dist/index-CQJFGBWr.d.ts +8 -0
- package/dist/index-DBbTnSBj.d.ts +18 -0
- package/dist/index-DEC0eIj4.d.ts +18 -0
- package/dist/index-DZ7D8MkM.d.ts +18 -0
- package/dist/index-IqUGJ_D5.d.ts +8 -0
- package/dist/index-VKTbyIEw.d.ts +18 -0
- package/dist/index-pIxMzJ5o.d.ts +18 -0
- package/dist/index-vrb8mA6n.d.ts +18 -0
- package/dist/index.d.ts +48 -0
- package/dist/index.mjs +21 -0
- package/dist/ky/index.d.ts +9 -0
- package/dist/ky/index.mjs +7 -0
- package/dist/ky/js/config/index.d.ts +5 -0
- package/dist/ky/js/config/index.mjs +18 -0
- package/dist/ky/js/index.d.ts +6 -0
- package/dist/ky/js/index.mjs +25 -0
- package/dist/ky/js/parser/index.d.ts +12 -0
- package/dist/ky/js/parser/index.mjs +79 -0
- package/dist/ky/ts/config/index.d.ts +5 -0
- package/dist/ky/ts/config/index.mjs +22 -0
- package/dist/ky/ts/index.d.ts +6 -0
- package/dist/ky/ts/index.mjs +25 -0
- package/dist/ky/ts/parser/index.d.ts +12 -0
- package/dist/ky/ts/parser/index.mjs +78 -0
- package/dist/ofetch/index.d.ts +9 -0
- package/dist/ofetch/index.mjs +7 -0
- package/dist/ofetch/js/config/index.d.ts +5 -0
- package/dist/ofetch/js/config/index.mjs +18 -0
- package/dist/ofetch/js/index.d.ts +6 -0
- package/dist/ofetch/js/index.mjs +25 -0
- package/dist/ofetch/js/parser/index.d.ts +12 -0
- package/dist/ofetch/js/parser/index.mjs +78 -0
- package/dist/ofetch/ts/config/index.d.ts +5 -0
- package/dist/ofetch/ts/config/index.mjs +22 -0
- package/dist/ofetch/ts/index.d.ts +6 -0
- package/dist/ofetch/ts/index.mjs +25 -0
- package/dist/ofetch/ts/parser/index.d.ts +12 -0
- package/dist/ofetch/ts/parser/index.mjs +76 -0
- package/package.json +71 -0
- package/src/axios/index.ts +2 -0
- package/src/axios/js/config/index.ts +19 -0
- package/src/axios/js/index.ts +19 -0
- package/src/axios/js/parser/index.ts +96 -0
- package/src/axios/ts/config/index.ts +24 -0
- package/src/axios/ts/index.ts +20 -0
- package/src/axios/ts/parser/index.ts +95 -0
- package/src/fetch/index.ts +2 -0
- package/src/fetch/js/config/index.ts +12 -0
- package/src/fetch/js/index.ts +19 -0
- package/src/fetch/js/parser/index.ts +107 -0
- package/src/fetch/ts/config/index.ts +11 -0
- package/src/fetch/ts/index.ts +20 -0
- package/src/fetch/ts/parser/index.ts +98 -0
- package/src/got/index.ts +2 -0
- package/src/got/js/config/index.ts +19 -0
- package/src/got/js/index.ts +20 -0
- package/src/got/js/parser/index.ts +101 -0
- package/src/got/ts/config/index.ts +24 -0
- package/src/got/ts/index.ts +20 -0
- package/src/got/ts/parser/index.ts +102 -0
- package/src/index.ts +21 -0
- package/src/ky/index.ts +2 -0
- package/src/ky/js/config/index.ts +19 -0
- package/src/ky/js/index.ts +20 -0
- package/src/ky/js/parser/index.ts +97 -0
- package/src/ky/ts/config/index.ts +24 -0
- package/src/ky/ts/index.ts +20 -0
- package/src/ky/ts/parser/index.ts +97 -0
- package/src/ofetch/index.ts +2 -0
- package/src/ofetch/js/config/index.ts +19 -0
- package/src/ofetch/js/index.ts +20 -0
- package/src/ofetch/js/parser/index.ts +97 -0
- package/src/ofetch/ts/config/index.ts +24 -0
- package/src/ofetch/ts/index.ts +20 -0
- package/src/ofetch/ts/parser/index.ts +96 -0
- package/tsup.config.ts +18 -0
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export { i as js } from '../index-BnNpBsOT.js';
|
|
2
|
+
export { i as ts } from '../index-BIRCFgYi.js';
|
|
3
|
+
import '@genapi/shared';
|
|
4
|
+
import '@genapi/pipeline';
|
|
5
|
+
import './js/config/index.js';
|
|
6
|
+
import './js/parser/index.js';
|
|
7
|
+
import 'openapi-specification-types';
|
|
8
|
+
import './ts/config/index.js';
|
|
9
|
+
import './ts/parser/index.js';
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// src/got/js/config/index.ts
|
|
2
|
+
import { replaceMainext } from "@genapi/parser";
|
|
3
|
+
import { config as _config } from "@genapi/pipeline";
|
|
4
|
+
function config(userConfig) {
|
|
5
|
+
userConfig.import = userConfig.import || {};
|
|
6
|
+
userConfig.output = userConfig.output || {};
|
|
7
|
+
userConfig.import.http = userConfig.import.http || "got";
|
|
8
|
+
userConfig.output = replaceMainext(userConfig.output) || "src/api/index.js";
|
|
9
|
+
const configRead = _config(userConfig);
|
|
10
|
+
configRead.graphs.imports.push({
|
|
11
|
+
name: "http",
|
|
12
|
+
value: userConfig.import.http
|
|
13
|
+
});
|
|
14
|
+
return configRead;
|
|
15
|
+
}
|
|
16
|
+
export {
|
|
17
|
+
config
|
|
18
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import '@genapi/shared';
|
|
2
|
+
export { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
export { config } from './config/index.js';
|
|
4
|
+
export { parser } from './parser/index.js';
|
|
5
|
+
export { o as default } from '../../index-BnNpBsOT.js';
|
|
6
|
+
import 'openapi-specification-types';
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
// src/got/js/index.ts
|
|
2
|
+
import pipeline, { compiler, dest, generate, original } from "@genapi/pipeline";
|
|
3
|
+
import { config } from "./config/index.mjs";
|
|
4
|
+
import { parser } from "./parser/index.mjs";
|
|
5
|
+
function openapiPipeline(userConfig) {
|
|
6
|
+
const process = pipeline(
|
|
7
|
+
(userConfig2) => config(userConfig2),
|
|
8
|
+
(configRead) => original(configRead),
|
|
9
|
+
(configRead) => parser(configRead),
|
|
10
|
+
(configRead) => compiler(configRead),
|
|
11
|
+
(configRead) => generate(configRead),
|
|
12
|
+
(configRead) => dest(configRead)
|
|
13
|
+
);
|
|
14
|
+
return process(userConfig);
|
|
15
|
+
}
|
|
16
|
+
var js_default = openapiPipeline;
|
|
17
|
+
export {
|
|
18
|
+
compiler,
|
|
19
|
+
config,
|
|
20
|
+
js_default as default,
|
|
21
|
+
dest,
|
|
22
|
+
generate,
|
|
23
|
+
original,
|
|
24
|
+
parser
|
|
25
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ApiPipeline, StatementInterface, StatementFunction } from '@genapi/shared';
|
|
2
|
+
import { Paths } from 'openapi-specification-types';
|
|
3
|
+
|
|
4
|
+
interface PathsTransformOptions {
|
|
5
|
+
configRead: ApiPipeline.ConfigRead;
|
|
6
|
+
interfaces: StatementInterface[];
|
|
7
|
+
functions: StatementFunction[];
|
|
8
|
+
}
|
|
9
|
+
declare function parser(configRead: ApiPipeline.ConfigRead): ApiPipeline.ConfigRead<ApiPipeline.Config>;
|
|
10
|
+
declare function transformPaths(paths: Paths, { configRead, functions, interfaces }: PathsTransformOptions): void;
|
|
11
|
+
|
|
12
|
+
export { type PathsTransformOptions, parser, transformPaths };
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
// src/got/js/parser/index.ts
|
|
2
|
+
import {
|
|
3
|
+
literalFieldsToString,
|
|
4
|
+
parseHeaderCommits,
|
|
5
|
+
parseMethodMetadata,
|
|
6
|
+
parseMethodParameters,
|
|
7
|
+
parseOpenapiSpecification,
|
|
8
|
+
transformBaseURL,
|
|
9
|
+
transformBodyStringify,
|
|
10
|
+
transformDefinitions,
|
|
11
|
+
transformParameters,
|
|
12
|
+
transformQueryParams,
|
|
13
|
+
transformUrlSyntax,
|
|
14
|
+
traversePaths
|
|
15
|
+
} from "@genapi/parser";
|
|
16
|
+
function parser(configRead) {
|
|
17
|
+
const source = parseOpenapiSpecification(configRead.source);
|
|
18
|
+
const comments = parseHeaderCommits(source);
|
|
19
|
+
const interfaces = [];
|
|
20
|
+
const functions = [];
|
|
21
|
+
transformBaseURL(source, {
|
|
22
|
+
configRead
|
|
23
|
+
});
|
|
24
|
+
transformDefinitions(source.definitions, {
|
|
25
|
+
interfaces
|
|
26
|
+
});
|
|
27
|
+
transformPaths(source.paths, {
|
|
28
|
+
configRead,
|
|
29
|
+
functions,
|
|
30
|
+
interfaces
|
|
31
|
+
});
|
|
32
|
+
configRead.graphs.comments = comments;
|
|
33
|
+
configRead.graphs.functions = functions;
|
|
34
|
+
configRead.graphs.interfaces = interfaces;
|
|
35
|
+
return configRead;
|
|
36
|
+
}
|
|
37
|
+
function transformPaths(paths, { configRead, functions, interfaces }) {
|
|
38
|
+
traversePaths(paths, (config) => {
|
|
39
|
+
const { parameters, interfaces: attachInters, options } = parseMethodParameters(config);
|
|
40
|
+
let { name, description, url, responseType } = parseMethodMetadata(config);
|
|
41
|
+
interfaces.push(...attachInters);
|
|
42
|
+
parameters.push({
|
|
43
|
+
name: "config",
|
|
44
|
+
type: "import('got').OptionsOfTextResponseBody",
|
|
45
|
+
required: false
|
|
46
|
+
});
|
|
47
|
+
options.push(["...", "config"]);
|
|
48
|
+
if (configRead.config.baseURL)
|
|
49
|
+
options.unshift(["prefixUrl", "baseURL"]);
|
|
50
|
+
for (const parameter of parameters) {
|
|
51
|
+
if (parameter.type === "FormData")
|
|
52
|
+
parameter.type = "any";
|
|
53
|
+
}
|
|
54
|
+
transformParameters(parameters, {
|
|
55
|
+
syntax: "ecmascript",
|
|
56
|
+
configRead,
|
|
57
|
+
description,
|
|
58
|
+
interfaces,
|
|
59
|
+
responseType
|
|
60
|
+
});
|
|
61
|
+
transformBodyStringify("body", { options, parameters });
|
|
62
|
+
transformQueryParams("query", { optionKey: "searchParams", options });
|
|
63
|
+
url = transformUrlSyntax(url);
|
|
64
|
+
functions.push({
|
|
65
|
+
export: true,
|
|
66
|
+
async: true,
|
|
67
|
+
name,
|
|
68
|
+
description,
|
|
69
|
+
parameters,
|
|
70
|
+
body: [
|
|
71
|
+
`const response = await http(${url}, {
|
|
72
|
+
${literalFieldsToString(options)}
|
|
73
|
+
})`,
|
|
74
|
+
"return response.json()"
|
|
75
|
+
]
|
|
76
|
+
});
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
export {
|
|
80
|
+
parser,
|
|
81
|
+
transformPaths
|
|
82
|
+
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
// src/got/ts/config/index.ts
|
|
2
|
+
import { config as _config } from "@genapi/pipeline";
|
|
3
|
+
function config(userConfig) {
|
|
4
|
+
userConfig.import = userConfig.import || {};
|
|
5
|
+
userConfig.import.http = userConfig.import.http || "got";
|
|
6
|
+
const configRead = _config(userConfig);
|
|
7
|
+
configRead.graphs.imports.push({
|
|
8
|
+
name: "http",
|
|
9
|
+
names: userConfig.import.http === "got" ? ["OptionsOfTextResponseBody"] : void 0,
|
|
10
|
+
value: userConfig.import.http
|
|
11
|
+
});
|
|
12
|
+
if (userConfig.import.http !== "got") {
|
|
13
|
+
configRead.graphs.imports.push({
|
|
14
|
+
names: ["OptionsOfTextResponseBody"],
|
|
15
|
+
value: "got"
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
return configRead;
|
|
19
|
+
}
|
|
20
|
+
export {
|
|
21
|
+
config
|
|
22
|
+
};
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import '@genapi/shared';
|
|
2
|
+
export { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
export { config } from './config/index.js';
|
|
4
|
+
export { parser } from './parser/index.js';
|
|
5
|
+
export { o as default } from '../../index-BIRCFgYi.js';
|
|
6
|
+
import 'openapi-specification-types';
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
// src/got/ts/index.ts
|
|
2
|
+
import pipeline, { compiler, dest, generate, original } from "@genapi/pipeline";
|
|
3
|
+
import { config } from "./config/index.mjs";
|
|
4
|
+
import { parser } from "./parser/index.mjs";
|
|
5
|
+
function openapiPipeline(userConfig) {
|
|
6
|
+
const process = pipeline(
|
|
7
|
+
(userConfig2) => config(userConfig2),
|
|
8
|
+
(configRead) => original(configRead),
|
|
9
|
+
(configRead) => parser(configRead),
|
|
10
|
+
(configRead) => compiler(configRead),
|
|
11
|
+
(configRead) => generate(configRead),
|
|
12
|
+
(configRead) => dest(configRead)
|
|
13
|
+
);
|
|
14
|
+
return process(userConfig);
|
|
15
|
+
}
|
|
16
|
+
var ts_default = openapiPipeline;
|
|
17
|
+
export {
|
|
18
|
+
compiler,
|
|
19
|
+
config,
|
|
20
|
+
ts_default as default,
|
|
21
|
+
dest,
|
|
22
|
+
generate,
|
|
23
|
+
original,
|
|
24
|
+
parser
|
|
25
|
+
};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { ApiPipeline, StatementInterface, StatementFunction } from '@genapi/shared';
|
|
2
|
+
import { Paths } from 'openapi-specification-types';
|
|
3
|
+
|
|
4
|
+
interface PathsTransformOptions {
|
|
5
|
+
configRead: ApiPipeline.ConfigRead;
|
|
6
|
+
interfaces: StatementInterface[];
|
|
7
|
+
functions: StatementFunction[];
|
|
8
|
+
}
|
|
9
|
+
declare function parser(configRead: ApiPipeline.ConfigRead): ApiPipeline.ConfigRead<ApiPipeline.Config>;
|
|
10
|
+
declare function transformPaths(paths: Paths, { configRead, functions, interfaces }: PathsTransformOptions): void;
|
|
11
|
+
|
|
12
|
+
export { type PathsTransformOptions, parser, transformPaths };
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
// src/got/ts/parser/index.ts
|
|
2
|
+
import {
|
|
3
|
+
literalFieldsToString,
|
|
4
|
+
parseHeaderCommits,
|
|
5
|
+
parseMethodMetadata,
|
|
6
|
+
parseMethodParameters,
|
|
7
|
+
parseOpenapiSpecification,
|
|
8
|
+
transformBaseURL,
|
|
9
|
+
transformBodyStringify,
|
|
10
|
+
transformDefinitions,
|
|
11
|
+
transformParameters,
|
|
12
|
+
transformQueryParams,
|
|
13
|
+
transformUrlSyntax,
|
|
14
|
+
traversePaths
|
|
15
|
+
} from "@genapi/parser";
|
|
16
|
+
function parser(configRead) {
|
|
17
|
+
const source = parseOpenapiSpecification(configRead.source);
|
|
18
|
+
const comments = parseHeaderCommits(source);
|
|
19
|
+
const interfaces = [];
|
|
20
|
+
const functions = [];
|
|
21
|
+
transformBaseURL(source, {
|
|
22
|
+
configRead
|
|
23
|
+
});
|
|
24
|
+
transformDefinitions(source.definitions, {
|
|
25
|
+
interfaces
|
|
26
|
+
});
|
|
27
|
+
transformPaths(source.paths, {
|
|
28
|
+
configRead,
|
|
29
|
+
functions,
|
|
30
|
+
interfaces
|
|
31
|
+
});
|
|
32
|
+
configRead.graphs.comments = comments;
|
|
33
|
+
configRead.graphs.functions = functions;
|
|
34
|
+
configRead.graphs.interfaces = interfaces;
|
|
35
|
+
return configRead;
|
|
36
|
+
}
|
|
37
|
+
function transformPaths(paths, { configRead, functions, interfaces }) {
|
|
38
|
+
traversePaths(paths, (config) => {
|
|
39
|
+
const { parameters, interfaces: attachInters, options } = parseMethodParameters(config);
|
|
40
|
+
let { name, description, url, responseType } = parseMethodMetadata(config);
|
|
41
|
+
interfaces.push(...attachInters);
|
|
42
|
+
parameters.push({
|
|
43
|
+
name: "config",
|
|
44
|
+
type: "OptionsOfTextResponseBody",
|
|
45
|
+
required: false
|
|
46
|
+
});
|
|
47
|
+
options.push(["...", "config"]);
|
|
48
|
+
if (configRead.config.baseURL)
|
|
49
|
+
options.unshift(["prefixUrl", "baseURL"]);
|
|
50
|
+
for (const parameter of parameters) {
|
|
51
|
+
if (parameter.type === "FormData")
|
|
52
|
+
parameter.type = "any";
|
|
53
|
+
}
|
|
54
|
+
const { spaceResponseType } = transformParameters(parameters, {
|
|
55
|
+
syntax: "typescript",
|
|
56
|
+
configRead,
|
|
57
|
+
description,
|
|
58
|
+
interfaces,
|
|
59
|
+
responseType
|
|
60
|
+
});
|
|
61
|
+
transformBodyStringify("body", { options, parameters });
|
|
62
|
+
transformQueryParams("query", { optionKey: "searchParams", options });
|
|
63
|
+
url = transformUrlSyntax(url);
|
|
64
|
+
functions.push({
|
|
65
|
+
export: true,
|
|
66
|
+
async: true,
|
|
67
|
+
name,
|
|
68
|
+
description,
|
|
69
|
+
parameters,
|
|
70
|
+
body: [
|
|
71
|
+
`const response = http.${config.method}(${url}, {
|
|
72
|
+
${literalFieldsToString(options)}
|
|
73
|
+
})`,
|
|
74
|
+
`return response.json<${spaceResponseType}>()`
|
|
75
|
+
]
|
|
76
|
+
});
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
export {
|
|
80
|
+
parser,
|
|
81
|
+
transformPaths
|
|
82
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './axios/js/config/index.js';
|
|
4
|
+
import { parser } from './axios/js/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './got/ts/config/index.js';
|
|
4
|
+
import { parser } from './got/ts/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './ofetch/js/config/index.js';
|
|
4
|
+
import { parser } from './ofetch/js/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './got/js/config/index.js';
|
|
4
|
+
import { parser } from './got/js/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './axios/ts/config/index.js';
|
|
4
|
+
import { parser } from './axios/ts/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './ky/ts/config/index.js';
|
|
4
|
+
import { parser } from './ky/ts/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './ky/js/config/index.js';
|
|
4
|
+
import { parser } from './ky/js/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './ofetch/ts/config/index.js';
|
|
4
|
+
import { parser } from './ofetch/ts/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './fetch/js/config/index.js';
|
|
4
|
+
import { parser } from './fetch/js/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { ApiPipeline } from '@genapi/shared';
|
|
2
|
+
import { compiler, dest, generate, original } from '@genapi/pipeline';
|
|
3
|
+
import { config } from './fetch/ts/config/index.js';
|
|
4
|
+
import { parser } from './fetch/ts/parser/index.js';
|
|
5
|
+
|
|
6
|
+
declare function openapiPipeline(userConfig: ApiPipeline.Config): Promise<void>;
|
|
7
|
+
|
|
8
|
+
declare const index_compiler: typeof compiler;
|
|
9
|
+
declare const index_config: typeof config;
|
|
10
|
+
declare const index_dest: typeof dest;
|
|
11
|
+
declare const index_generate: typeof generate;
|
|
12
|
+
declare const index_original: typeof original;
|
|
13
|
+
declare const index_parser: typeof parser;
|
|
14
|
+
declare namespace index {
|
|
15
|
+
export { index_compiler as compiler, index_config as config, openapiPipeline as default, index_dest as dest, index_generate as generate, index_original as original, index_parser as parser };
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export { index as i, openapiPipeline as o };
|
package/dist/index.d.ts
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { a as axios } from './index-IqUGJ_D5.js';
|
|
2
|
+
import { f as fetch } from './index-CQJFGBWr.js';
|
|
3
|
+
import { g as got } from './index--xiziIvG.js';
|
|
4
|
+
import { k as ky } from './index-BWvY4w5U.js';
|
|
5
|
+
import { o as ofetch } from './index-CApSnKVf.js';
|
|
6
|
+
import './index-BByL5W2V.js';
|
|
7
|
+
import '@genapi/shared';
|
|
8
|
+
import '@genapi/pipeline';
|
|
9
|
+
import './axios/js/config/index.js';
|
|
10
|
+
import './axios/js/parser/index.js';
|
|
11
|
+
import 'openapi-specification-types';
|
|
12
|
+
import './index-DBbTnSBj.js';
|
|
13
|
+
import './axios/ts/config/index.js';
|
|
14
|
+
import './axios/ts/parser/index.js';
|
|
15
|
+
import './index-pIxMzJ5o.js';
|
|
16
|
+
import './fetch/js/config/index.js';
|
|
17
|
+
import './fetch/js/parser/index.js';
|
|
18
|
+
import './index-vrb8mA6n.js';
|
|
19
|
+
import './fetch/ts/config/index.js';
|
|
20
|
+
import './fetch/ts/parser/index.js';
|
|
21
|
+
import './index-BnNpBsOT.js';
|
|
22
|
+
import './got/js/config/index.js';
|
|
23
|
+
import './got/js/parser/index.js';
|
|
24
|
+
import './index-BIRCFgYi.js';
|
|
25
|
+
import './got/ts/config/index.js';
|
|
26
|
+
import './got/ts/parser/index.js';
|
|
27
|
+
import './index-DZ7D8MkM.js';
|
|
28
|
+
import './ky/js/config/index.js';
|
|
29
|
+
import './ky/js/parser/index.js';
|
|
30
|
+
import './index-DEC0eIj4.js';
|
|
31
|
+
import './ky/ts/config/index.js';
|
|
32
|
+
import './ky/ts/parser/index.js';
|
|
33
|
+
import './index-BJrp0lx3.js';
|
|
34
|
+
import './ofetch/js/config/index.js';
|
|
35
|
+
import './ofetch/js/parser/index.js';
|
|
36
|
+
import './index-VKTbyIEw.js';
|
|
37
|
+
import './ofetch/ts/config/index.js';
|
|
38
|
+
import './ofetch/ts/parser/index.js';
|
|
39
|
+
|
|
40
|
+
declare const _default: {
|
|
41
|
+
axios: typeof axios;
|
|
42
|
+
fetch: typeof fetch;
|
|
43
|
+
got: typeof got;
|
|
44
|
+
ky: typeof ky;
|
|
45
|
+
ofetch: typeof ofetch;
|
|
46
|
+
};
|
|
47
|
+
|
|
48
|
+
export { axios, _default as default, fetch, got, ky, ofetch };
|
package/dist/index.mjs
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// src/index.ts
|
|
2
|
+
import * as axios from "./axios/index.mjs";
|
|
3
|
+
import * as fetch from "./fetch/index.mjs";
|
|
4
|
+
import * as got from "./got/index.mjs";
|
|
5
|
+
import * as ky from "./ky/index.mjs";
|
|
6
|
+
import * as ofetch from "./ofetch/index.mjs";
|
|
7
|
+
var index_default = {
|
|
8
|
+
axios,
|
|
9
|
+
fetch,
|
|
10
|
+
got,
|
|
11
|
+
ky,
|
|
12
|
+
ofetch
|
|
13
|
+
};
|
|
14
|
+
export {
|
|
15
|
+
axios,
|
|
16
|
+
index_default as default,
|
|
17
|
+
fetch,
|
|
18
|
+
got,
|
|
19
|
+
ky,
|
|
20
|
+
ofetch
|
|
21
|
+
};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export { i as js } from '../index-DZ7D8MkM.js';
|
|
2
|
+
export { i as ts } from '../index-DEC0eIj4.js';
|
|
3
|
+
import '@genapi/shared';
|
|
4
|
+
import '@genapi/pipeline';
|
|
5
|
+
import './js/config/index.js';
|
|
6
|
+
import './js/parser/index.js';
|
|
7
|
+
import 'openapi-specification-types';
|
|
8
|
+
import './ts/config/index.js';
|
|
9
|
+
import './ts/parser/index.js';
|