@absolutejs/absolute 0.19.0-beta.1103 → 0.19.0-beta.1104

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.
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  var __require = import.meta.require;
3
3
 
4
- // .angular-partial-tmp-B8wHMF/src/core/streamingSlotRegistrar.ts
4
+ // .angular-partial-tmp-6xWN9E/src/core/streamingSlotRegistrar.ts
5
5
  var STREAMING_SLOT_REGISTRAR_KEY = Symbol.for("absolutejs.streamingSlotRegistrar");
6
6
  var STREAMING_SLOT_WARNING_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotWarningController");
7
7
  var STREAMING_SLOT_COLLECTION_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotCollectionController");
@@ -1,7 +1,7 @@
1
1
  // @bun
2
2
  var __require = import.meta.require;
3
3
 
4
- // .angular-partial-tmp-B8wHMF/src/core/streamingSlotRegistrar.ts
4
+ // .angular-partial-tmp-6xWN9E/src/core/streamingSlotRegistrar.ts
5
5
  var STREAMING_SLOT_REGISTRAR_KEY = Symbol.for("absolutejs.streamingSlotRegistrar");
6
6
  var STREAMING_SLOT_WARNING_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotWarningController");
7
7
  var STREAMING_SLOT_COLLECTION_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotCollectionController");
@@ -48,7 +48,7 @@ var warnMissingStreamingSlotCollector = (primitiveName) => {
48
48
  getWarningController()?.maybeWarn(primitiveName);
49
49
  };
50
50
 
51
- // .angular-partial-tmp-B8wHMF/src/core/streamingSlotRegistry.ts
51
+ // .angular-partial-tmp-6xWN9E/src/core/streamingSlotRegistry.ts
52
52
  var STREAMING_SLOT_STORAGE_KEY = Symbol.for("absolutejs.streamingSlotAsyncLocalStorage");
53
53
  var isObjectRecord2 = (value) => Boolean(value) && typeof value === "object";
54
54
  var isAsyncLocalStorage = (value) => isObjectRecord2(value) && ("getStore" in value) && typeof value.getStore === "function" && ("run" in value) && typeof value.run === "function";
@@ -5251,6 +5251,13 @@ ${fields}
5251
5251
  }
5252
5252
  result += source.slice(lastIndex);
5253
5253
  return result;
5254
+ }, PROVIDERS_INJECTION_BLOCK_RE, readPreservedInjection = async (targetPath) => {
5255
+ try {
5256
+ const existing = await fs.readFile(targetPath, "utf-8");
5257
+ return PROVIDERS_INJECTION_BLOCK_RE.exec(existing)?.[0] ?? "";
5258
+ } catch {
5259
+ return "";
5260
+ }
5254
5261
  }, compileAngularFileJIT = async (inputPath, outDir, rootDir, stylePreprocessors, cacheBuster) => {
5255
5262
  const entryPath = resolve7(inputPath);
5256
5263
  const allOutputs = [];
@@ -5408,8 +5415,9 @@ ${fields}
5408
5415
  const shouldWriteFile = cacheBuster && isEntry ? true : jitContentCache.get(cacheKey) !== contentHash || !existsSync5(targetPath);
5409
5416
  if (shouldWriteFile) {
5410
5417
  const processedContent = transpileAndRewrite(sourceCode, relativeDir, actualPath, importRewrites);
5418
+ const preservedInjection = await readPreservedInjection(targetPath);
5411
5419
  await fs.mkdir(targetDir, { recursive: true });
5412
- await fs.writeFile(targetPath, processedContent, "utf-8");
5420
+ await fs.writeFile(targetPath, processedContent + preservedInjection, "utf-8");
5413
5421
  jitContentCache.set(cacheKey, contentHash);
5414
5422
  }
5415
5423
  allOutputs.push(targetPath);
@@ -5795,6 +5803,7 @@ var init_compileAngular = __esm(() => {
5795
5803
  hmrClientPath = join9(devClientDir, "hmrClient.ts").replace(/\\/g, "/");
5796
5804
  jitContentCache = new Map;
5797
5805
  wrapperOutputCache = new Map;
5806
+ PROVIDERS_INJECTION_BLOCK_RE = /\n\/\* __ABS_PROVIDERS_INJECTION_START \*\/[\s\S]*?\/\* __ABS_PROVIDERS_INJECTION_END \*\/\n?/;
5798
5807
  });
5799
5808
 
5800
5809
  // node_modules/rxjs/dist/cjs/internal/util/isFunction.js
@@ -16177,5 +16186,5 @@ export {
16177
16186
  ABSOLUTE_HTTP_TRANSFER_CACHE_SKIP_HEADER
16178
16187
  };
16179
16188
 
16180
- //# debugId=CBA1BAF2069BB52564756E2164756E21
16189
+ //# debugId=F890201244D3364E64756E2164756E21
16181
16190
  //# sourceMappingURL=index.js.map