@absolutejs/absolute 0.19.0-beta.985 → 0.19.0-beta.986

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.
@@ -4488,7 +4488,19 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
4488
4488
  const detectedClassName = await traceAngularPhase("wrapper/detect-component-class", () => detectExportedComponentClass(original), { entry: resolvedEntry });
4489
4489
  const componentClassName = detectedClassName ?? `${toPascal(fileBase)}Component`;
4490
4490
  const usesLegacyAnimations = await traceAngularPhase("wrapper/detect-legacy-animations", () => usesLegacyAngularAnimations(resolvedEntry), { entry: resolvedEntry });
4491
- const serverContentHash = Bun.hash(original).toString(BASE_36_RADIX);
4491
+ const pageInjectionForHash = providersInjection?.pagesByFile.get(resolvedEntry);
4492
+ const providersHashInput = providersInjection ? (() => {
4493
+ let providersSourceContent = "";
4494
+ try {
4495
+ providersSourceContent = readFileSync4(providersInjection.appProvidersSource, "utf-8");
4496
+ } catch {}
4497
+ return JSON.stringify({
4498
+ basePath: pageInjectionForHash?.basePath ?? null,
4499
+ hasRoutes: pageInjectionForHash?.hasRoutes ?? false,
4500
+ source: providersSourceContent
4501
+ });
4502
+ })() : "no-providers";
4503
+ const serverContentHash = `${Bun.hash(original).toString(BASE_36_RADIX)}.${Bun.hash(providersHashInput).toString(BASE_36_RADIX)}`;
4492
4504
  const cachedWrapper = wrapperOutputCache.get(resolvedEntry);
4493
4505
  const clientFile = join7(indexesDir, jsName);
4494
4506
  if (hmr && cachedWrapper && cachedWrapper.serverHash === serverContentHash && existsSync4(clientFile) && (usesLegacyAnimations || !original.includes("__ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__")) && (!usesLegacyAnimations || original.includes("__ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__"))) {
@@ -4516,6 +4528,7 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
4516
4528
  `;
4517
4529
  }
4518
4530
  const pageInjection = providersInjection?.pagesByFile.get(resolvedEntry);
4531
+ rewritten = rewritten.replace(/\n\/\* __ABS_PROVIDERS_INJECTION_START \*\/[\s\S]*?\/\* __ABS_PROVIDERS_INJECTION_END \*\/\n?/g, "");
4519
4532
  if (providersInjection && pageInjection) {
4520
4533
  const compiledAppProvidersPath = (() => {
4521
4534
  const angularDirAbs = resolve6(outRoot);
@@ -4540,9 +4553,11 @@ export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
4540
4553
  fragments.push(`{ provide: __abs_APP_BASE_HREF, useValue: ${JSON.stringify(pageInjection.basePath)} }`);
4541
4554
  }
4542
4555
  rewritten += `
4556
+ /* __ABS_PROVIDERS_INJECTION_START */
4543
4557
  ${importLines.join(`
4544
4558
  `)}
4545
4559
  export const providers = [${fragments.join(", ")}];
4560
+ /* __ABS_PROVIDERS_INJECTION_END */
4546
4561
  `;
4547
4562
  }
4548
4563
  await traceAngularPhase("wrapper/write-server-output", () => fs.writeFile(rawServerFile, rewritten, "utf-8"), { entry: resolvedEntry });
@@ -5939,5 +5954,5 @@ export {
5939
5954
  ABSOLUTE_HTTP_TRANSFER_CACHE_SKIP_HEADER
5940
5955
  };
5941
5956
 
5942
- //# debugId=7826DBC0E4B1EBEE64756E2164756E21
5957
+ //# debugId=9CB8DA574576169764756E2164756E21
5943
5958
  //# sourceMappingURL=server.js.map