@eventcatalog/sdk 2.27.2 → 2.27.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/index.d.mts CHANGED
@@ -1351,13 +1351,11 @@ type HydrateOptions = {
1351
1351
  outDir: string;
1352
1352
  localSource?: string;
1353
1353
  fetch: Fetcher;
1354
- modes?: Record<string, 'hydrate' | 'reference'>;
1355
1354
  cache?: Cache;
1356
1355
  };
1357
1356
  type HydrateResult = {
1358
1357
  fetched: number;
1359
1358
  written: number;
1360
- referenced: number;
1361
1359
  };
1362
1360
  declare function hydrate(graph: ResolvedGraph, options: HydrateOptions): Promise<HydrateResult>;
1363
1361
 
package/dist/index.d.ts CHANGED
@@ -1351,13 +1351,11 @@ type HydrateOptions = {
1351
1351
  outDir: string;
1352
1352
  localSource?: string;
1353
1353
  fetch: Fetcher;
1354
- modes?: Record<string, 'hydrate' | 'reference'>;
1355
1354
  cache?: Cache;
1356
1355
  };
1357
1356
  type HydrateResult = {
1358
1357
  fetched: number;
1359
1358
  written: number;
1360
- referenced: number;
1361
1359
  };
1362
1360
  declare function hydrate(graph: ResolvedGraph, options: HydrateOptions): Promise<HydrateResult>;
1363
1361
 
package/dist/index.js CHANGED
@@ -676,7 +676,7 @@ function buildFileCache(catalogDir) {
676
676
  const canonicalCatalogDir = toCanonicalPath(catalogDir);
677
677
  const files = (0, import_glob2.globSync)("**/index.{md,mdx}", {
678
678
  cwd: canonicalCatalogDir,
679
- ignore: ["node_modules/**"],
679
+ ignore: ["node_modules/**", "dist/**", ".eventcatalog-core/**"],
680
680
  absolute: true,
681
681
  nodir: true
682
682
  }).map(import_node_path.normalize);
@@ -819,7 +819,7 @@ var getFiles = async (pattern, ignore2 = "") => {
819
819
  const ignoreList = Array.isArray(ignore2) ? ignore2 : [ignore2];
820
820
  const files = (0, import_glob2.globSync)(relativePattern, {
821
821
  cwd: absoluteBaseDir,
822
- ignore: ["node_modules/**", ...ignoreList],
822
+ ignore: ["node_modules/**", "dist/**", ".eventcatalog-core/**", ...ignoreList],
823
823
  absolute: true,
824
824
  nodir: true
825
825
  });
@@ -4481,17 +4481,12 @@ var replaceDirectory = async (stagingDirectory, outDir) => {
4481
4481
  async function hydrate(graph, options) {
4482
4482
  const result = {
4483
4483
  fetched: 0,
4484
- written: 0,
4485
- referenced: 0
4484
+ written: 0
4486
4485
  };
4487
4486
  const artifacts = [];
4488
4487
  for (const entity of graph.entities) {
4489
4488
  const { source, commit } = entity.resolvedFrom;
4490
4489
  if (options.localSource !== void 0 && source === options.localSource) continue;
4491
- if (options.modes?.[source] === "reference") {
4492
- result.referenced++;
4493
- continue;
4494
- }
4495
4490
  if (!entity.contentPath) continue;
4496
4491
  artifacts.push({
4497
4492
  source,
@@ -4528,8 +4523,7 @@ async function hydrate(graph, options) {
4528
4523
  }
4529
4524
  for (const asset of graph.assets) {
4530
4525
  const { source, commit } = asset.resolvedFrom;
4531
- if (options.localSource !== void 0 && source === options.localSource || options.modes?.[source] === "reference")
4532
- continue;
4526
+ if (options.localSource !== void 0 && source === options.localSource) continue;
4533
4527
  artifacts.push({
4534
4528
  source,
4535
4529
  commit,