@kubb/core 5.0.0-beta.64 → 5.0.0-beta.66
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/{diagnostics-BqiNAWVS.d.ts → diagnostics-M8ckppMO.d.ts} +1 -5
- package/dist/index.cjs +6 -8
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +8 -9
- package/dist/index.js.map +1 -1
- package/dist/{memoryStorage-mojU6pbA.cjs → memoryStorage-67VG6jZn.cjs} +3 -4
- package/dist/memoryStorage-67VG6jZn.cjs.map +1 -0
- package/dist/{memoryStorage-DWnhqUf2.js → memoryStorage-D0gb5tRV.js} +3 -3
- package/dist/memoryStorage-D0gb5tRV.js.map +1 -0
- package/dist/mocks.cjs +1 -1
- package/dist/mocks.d.ts +1 -1
- package/dist/mocks.js +1 -1
- package/package.json +4 -4
- package/dist/memoryStorage-DWnhqUf2.js.map +0 -1
- package/dist/memoryStorage-mojU6pbA.cjs.map +0 -1
|
@@ -114,7 +114,6 @@ type PossiblePromise<T> = Promise<T> | T;
|
|
|
114
114
|
* input shape with paths resolved to absolute.
|
|
115
115
|
*
|
|
116
116
|
* - `{ type: 'path' }`: single file on disk.
|
|
117
|
-
* - `{ type: 'paths' }`: multiple files (e.g. split spec).
|
|
118
117
|
* - `{ type: 'data' }`: raw string or parsed object provided inline.
|
|
119
118
|
*/
|
|
120
119
|
type AdapterSource = {
|
|
@@ -123,9 +122,6 @@ type AdapterSource = {
|
|
|
123
122
|
} | {
|
|
124
123
|
type: 'data';
|
|
125
124
|
data: string | unknown;
|
|
126
|
-
} | {
|
|
127
|
-
type: 'paths';
|
|
128
|
-
paths: Array<string>;
|
|
129
125
|
};
|
|
130
126
|
/**
|
|
131
127
|
* Generic parameters used by `createAdapter` and the resulting `Adapter` type.
|
|
@@ -2908,4 +2904,4 @@ declare class Diagnostics {
|
|
|
2908
2904
|
}
|
|
2909
2905
|
//#endregion
|
|
2910
2906
|
export { KubbPluginSetupContext as $, KubbHookStartContext as A, Adapter as At, ParsedFile as B, KubbFilesProcessingEndContext as C, GenerationResult as Ct, KubbGenerationStartContext as D, UserReporter as Dt, KubbGenerationEndContext as E, ReporterName as Et, KubbSuccessContext as F, Generator$1 as G, createKubb as H, KubbWarnContext as I, KubbDriver as J, GeneratorContext as K, PossibleConfig as L, KubbInfoContext as M, AdapterSource as Mt, KubbLifecycleStartContext as N, createAdapter as Nt, KubbHookEndContext as O, createReporter as Ot, KubbPluginsEndContext as P, AsyncEventEmitter as Pt, KubbPluginEndContext as Q, UserConfig as R, KubbFileProcessingUpdate as S, createStorage as St, KubbFilesProcessingUpdateContext as T, ReporterContext as Tt, Parser as U, Kubb$1 as V, defineParser as W, Group as X, Exclude$1 as Y, Include as Z, InputPath as _, defineResolver as _t, DiagnosticLocation as a, Override as at, KubbDiagnosticContext as b, createRenderer as bt, PerformanceDiagnostic as c, definePlugin as ct, SerializedDiagnostic as d, ResolveBannerFile as dt, KubbPluginStartContext as et, UpdateDiagnostic as f, ResolveOptionsContext as ft, InputData as g, ResolverPathParams as gt, Config as h, ResolverFileParams as ht, DiagnosticKind as i, OutputOptions as it, KubbHooks as j, AdapterFactoryOptions as jt, KubbHookLineContext as k, logLevel as kt, ProblemCode as l, BannerMeta as lt, CLIOptions as m, ResolverContext as mt, DiagnosticByCode as n, Output as nt, DiagnosticSeverity as o, Plugin as ot, BuildOutput as p, Resolver as pt, defineGenerator as q, DiagnosticDoc as r, OutputMode as rt, Diagnostics as s, PluginFactoryOptions as st, Diagnostic as t, NormalizedPlugin as tt, ProblemDiagnostic as u, ResolveBannerContext as ut, KubbBuildEndContext as v, Renderer as vt, KubbFilesProcessingStartContext as w, Reporter as wt, KubbErrorContext as x, Storage as xt, KubbBuildStartContext as y, RendererFactory as yt, FileProcessorHooks as z };
|
|
2911
|
-
//# sourceMappingURL=diagnostics-
|
|
2907
|
+
//# sourceMappingURL=diagnostics-M8ckppMO.d.ts.map
|
package/dist/index.cjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
-
const require_memoryStorage = require("./memoryStorage-
|
|
2
|
+
const require_memoryStorage = require("./memoryStorage-67VG6jZn.cjs");
|
|
3
3
|
let node_crypto = require("node:crypto");
|
|
4
4
|
let node_util = require("node:util");
|
|
5
5
|
let node_fs_promises = require("node:fs/promises");
|
|
@@ -7,8 +7,6 @@ let node_path = require("node:path");
|
|
|
7
7
|
node_path = require_memoryStorage.__toESM(node_path, 1);
|
|
8
8
|
let _kubb_ast = require("@kubb/ast");
|
|
9
9
|
let node_async_hooks = require("node:async_hooks");
|
|
10
|
-
let _kubb_ast_factory = require("@kubb/ast/factory");
|
|
11
|
-
_kubb_ast_factory = require_memoryStorage.__toESM(_kubb_ast_factory, 1);
|
|
12
10
|
let _kubb_ast_utils = require("@kubb/ast/utils");
|
|
13
11
|
let node_process = require("node:process");
|
|
14
12
|
node_process = require_memoryStorage.__toESM(node_process, 1);
|
|
@@ -610,7 +608,7 @@ function createAdapter(build) {
|
|
|
610
608
|
/**
|
|
611
609
|
* Docs major version, derived from the package version so the link tracks the published major.
|
|
612
610
|
*/
|
|
613
|
-
const docsMajor = "5.0.0-beta.
|
|
611
|
+
const docsMajor = "5.0.0-beta.66".split(".")[0] ?? "5";
|
|
614
612
|
/**
|
|
615
613
|
* Narrows a {@link Diagnostic} to the variant for `code`, or `null` when it does not match.
|
|
616
614
|
*
|
|
@@ -1302,7 +1300,7 @@ function defaultResolveFile({ name, extname, tag, path: groupPath }, context) {
|
|
|
1302
1300
|
tag,
|
|
1303
1301
|
path: groupPath
|
|
1304
1302
|
}, context);
|
|
1305
|
-
return
|
|
1303
|
+
return _kubb_ast.ast.factory.createFile({
|
|
1306
1304
|
path: filePath,
|
|
1307
1305
|
baseName: node_path.default.basename(filePath),
|
|
1308
1306
|
meta: { pluginName: this.pluginName },
|
|
@@ -1673,7 +1671,7 @@ var KubbDriver = class {
|
|
|
1673
1671
|
/**
|
|
1674
1672
|
* Parses the adapter source into `this.inputNode`. Idempotent, so repeated calls from
|
|
1675
1673
|
* `run` do not re-parse. Adapters with `stream()` are used directly.
|
|
1676
|
-
* Adapters with only `parse()` are wrapped via `factory.createInput({ stream: true })` so the dispatch loop
|
|
1674
|
+
* Adapters with only `parse()` are wrapped via `ast.factory.createInput({ stream: true })` so the dispatch loop
|
|
1677
1675
|
* stays stream-only.
|
|
1678
1676
|
*/
|
|
1679
1677
|
async #parseInput() {
|
|
@@ -1685,7 +1683,7 @@ var KubbDriver = class {
|
|
|
1685
1683
|
return;
|
|
1686
1684
|
}
|
|
1687
1685
|
const parsed = await adapter.parse(source);
|
|
1688
|
-
this.inputNode =
|
|
1686
|
+
this.inputNode = _kubb_ast.ast.factory.createInput({
|
|
1689
1687
|
stream: true,
|
|
1690
1688
|
schemas: arrayToAsyncIterable(parsed.schemas),
|
|
1691
1689
|
operations: arrayToAsyncIterable(parsed.operations),
|
|
@@ -1737,7 +1735,7 @@ var KubbDriver = class {
|
|
|
1737
1735
|
}
|
|
1738
1736
|
},
|
|
1739
1737
|
injectFile: (userFileNode) => {
|
|
1740
|
-
this.fileManager.add(
|
|
1738
|
+
this.fileManager.add(_kubb_ast.ast.factory.createFile(userFileNode));
|
|
1741
1739
|
}
|
|
1742
1740
|
};
|
|
1743
1741
|
return hooks["kubb:plugin:setup"](pluginCtx);
|