@kubb/studio 5.6.3 → 5.8.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/dist/index.cjs +5 -5
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +6 -6
- package/dist/index.js.map +1 -1
- package/package.json +5 -5
package/dist/index.cjs
CHANGED
|
@@ -216,7 +216,7 @@ function getElapsedMs(hrStart) {
|
|
|
216
216
|
}
|
|
217
217
|
//#endregion
|
|
218
218
|
//#region package.json
|
|
219
|
-
var version = "5.
|
|
219
|
+
var version = "5.8.0";
|
|
220
220
|
//#endregion
|
|
221
221
|
//#region src/resolveConfig.ts
|
|
222
222
|
/**
|
|
@@ -485,7 +485,7 @@ function mergeOptions(disk, studio) {
|
|
|
485
485
|
*/
|
|
486
486
|
async function mergePlugins(diskPlugins, studioPlugins) {
|
|
487
487
|
const disabledNames = new Set((studioPlugins ?? []).filter((entry) => entry.disabled).map((entry) => toPluginName(entry.name)));
|
|
488
|
-
const activeDiskPlugins = disabledNames.size ? diskPlugins?.filter((plugin) => !disabledNames.has(plugin.name)) : diskPlugins;
|
|
488
|
+
const activeDiskPlugins = disabledNames.size ? diskPlugins?.filter((plugin) => !disabledNames.has((0, _kubb_core.resolveMeta)(plugin).name)) : diskPlugins;
|
|
489
489
|
const activeStudioPlugins = studioPlugins?.filter((entry) => !entry.disabled);
|
|
490
490
|
if (!activeDiskPlugins && !activeStudioPlugins?.length) return void 0;
|
|
491
491
|
if (!activeStudioPlugins?.length) return activeDiskPlugins;
|
|
@@ -493,7 +493,7 @@ async function mergePlugins(diskPlugins, studioPlugins) {
|
|
|
493
493
|
const studioEntryByName = new Map(activeStudioPlugins.map((entry) => [toPluginName(entry.name), entry]));
|
|
494
494
|
const diskNames = new Set(activeDiskPlugins.map((plugin) => plugin.name));
|
|
495
495
|
const merged = await Promise.all(activeDiskPlugins.map(async (diskPlugin) => {
|
|
496
|
-
const studioEntry = studioEntryByName.get(diskPlugin.name);
|
|
496
|
+
const studioEntry = studioEntryByName.get((0, _kubb_core.resolveMeta)(diskPlugin).name);
|
|
497
497
|
if (!studioEntry) return diskPlugin;
|
|
498
498
|
const diskOptions = diskPlugin.options ?? {};
|
|
499
499
|
const options = mergeOptions(diskOptions, studioEntry.options ?? {});
|
|
@@ -1584,7 +1584,7 @@ var Agent = class extends capnweb.RpcTarget {
|
|
|
1584
1584
|
file,
|
|
1585
1585
|
plugins: config.plugins.map((plugin) => ({
|
|
1586
1586
|
name: toStudioName({
|
|
1587
|
-
name: plugin.name,
|
|
1587
|
+
name: (0, _kubb_core.resolveMeta)(plugin).name,
|
|
1588
1588
|
root
|
|
1589
1589
|
}),
|
|
1590
1590
|
options: toJSONOptions(plugin.options)
|
|
@@ -2223,7 +2223,7 @@ async function createSnapshot({ studioUrl = defaultStudioUrl, apiKey, config, ho
|
|
|
2223
2223
|
if (content === null) throw new Error(`The generation listed ${path} but did not keep its content`);
|
|
2224
2224
|
return [path, content];
|
|
2225
2225
|
})));
|
|
2226
|
-
const { peerDependencies, missingDependencies } = await resolvePeerDependencies(config.plugins.map((
|
|
2226
|
+
const { peerDependencies, missingDependencies } = await resolvePeerDependencies(config.plugins.map((plugin) => (0, _kubb_core.resolveMeta)(plugin).name));
|
|
2227
2227
|
const missing = missingDependencies.filter((dependency) => !BUNDLED_DEPENDENCIES.includes(dependency));
|
|
2228
2228
|
if (missing.length) throw new Error(`Missing dependencies: ${missing.join(", ")}`);
|
|
2229
2229
|
const bytes = await createSnapshotPackage({
|