@absolutejs/absolute 0.19.0-beta.71 → 0.19.0-beta.73
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/.absolutejs/tsconfig.tsbuildinfo +1 -1
- package/.claude/settings.local.json +2 -1
- package/dist/build.js +7 -45
- package/dist/build.js.map +4 -4
- package/dist/index.js +7 -45
- package/dist/index.js.map +4 -4
- package/package.json +1 -1
|
@@ -233,7 +233,8 @@
|
|
|
233
233
|
"Bash(sed -i 's/\"\"\"\"@absolutejs\\\\/absolute\"\"\"\": \"\"\"\"0.19.0-beta.67\"\"\"\"/\"\"\"\"@absolutejs\\\\/absolute\"\"\"\": \"\"\"\"0.19.0-beta.68\"\"\"\"/' package.json)",
|
|
234
234
|
"Bash(./scripts/use-patched-bun.sh echo:*)",
|
|
235
235
|
"Read(//home/alexkahn/alex/bun-transpiler-patch/build/release/**)",
|
|
236
|
-
"Bash(~/alex/bun-transpiler-patch/build/release/bun --version)"
|
|
236
|
+
"Bash(~/alex/bun-transpiler-patch/build/release/bun --version)",
|
|
237
|
+
"Bash(lsof -ti:3000)"
|
|
237
238
|
]
|
|
238
239
|
}
|
|
239
240
|
}
|
package/dist/build.js
CHANGED
|
@@ -202323,15 +202323,6 @@ var init_pageHandler = __esm(() => {
|
|
|
202323
202323
|
});
|
|
202324
202324
|
|
|
202325
202325
|
// src/dev/transformCache.ts
|
|
202326
|
-
var exports_transformCache = {};
|
|
202327
|
-
__export(exports_transformCache, {
|
|
202328
|
-
setTransformed: () => setTransformed,
|
|
202329
|
-
invalidateAll: () => invalidateAll,
|
|
202330
|
-
invalidate: () => invalidate,
|
|
202331
|
-
getTransformed: () => getTransformed,
|
|
202332
|
-
getInvalidationVersion: () => getInvalidationVersion,
|
|
202333
|
-
findNearestComponent: () => findNearestComponent
|
|
202334
|
-
});
|
|
202335
202326
|
var globalStore, cache, importers, getTransformed = (filePath) => cache.get(filePath)?.content, setTransformed = (filePath, content, mtime, imports) => {
|
|
202336
202327
|
const resolvedImports = imports ?? [];
|
|
202337
202328
|
cache.set(filePath, { content, imports: resolvedImports, mtime });
|
|
@@ -202350,28 +202341,6 @@ var globalStore, cache, importers, getTransformed = (filePath) => cache.get(file
|
|
|
202350
202341
|
cache.delete(parent);
|
|
202351
202342
|
}
|
|
202352
202343
|
}
|
|
202353
|
-
}, invalidateAll = () => {
|
|
202354
|
-
cache.clear();
|
|
202355
|
-
importers.clear();
|
|
202356
|
-
}, findNearestComponent = (filePath) => {
|
|
202357
|
-
const visited = new Set;
|
|
202358
|
-
const queue = [filePath];
|
|
202359
|
-
while (queue.length > 0) {
|
|
202360
|
-
const current = queue.shift();
|
|
202361
|
-
if (visited.has(current))
|
|
202362
|
-
continue;
|
|
202363
|
-
visited.add(current);
|
|
202364
|
-
const parents = importers.get(current);
|
|
202365
|
-
if (!parents)
|
|
202366
|
-
continue;
|
|
202367
|
-
for (const parent of parents) {
|
|
202368
|
-
if (parent.endsWith(".tsx") || parent.endsWith(".jsx")) {
|
|
202369
|
-
return parent;
|
|
202370
|
-
}
|
|
202371
|
-
queue.push(parent);
|
|
202372
|
-
}
|
|
202373
|
-
}
|
|
202374
|
-
return;
|
|
202375
202344
|
};
|
|
202376
202345
|
var init_transformCache = __esm(() => {
|
|
202377
202346
|
globalStore = globalThis;
|
|
@@ -202918,9 +202887,9 @@ export default {};
|
|
|
202918
202887
|
return files;
|
|
202919
202888
|
}, invalidateModule = (filePath) => {
|
|
202920
202889
|
const resolved = resolve17(filePath);
|
|
202921
|
-
console.log(`[invalidate] ${resolved} (cached: ${getTransformed(resolved) !== undefined}, cacheKeys: ${getTransformed(filePath) !== undefined})`);
|
|
202922
202890
|
invalidate(filePath);
|
|
202923
|
-
|
|
202891
|
+
if (resolved !== filePath)
|
|
202892
|
+
invalidate(resolved);
|
|
202924
202893
|
mtimeCache.delete(filePath);
|
|
202925
202894
|
mtimeCache.delete(resolved);
|
|
202926
202895
|
}, warmCache = (pathname) => {
|
|
@@ -203497,11 +203466,12 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, parseError
|
|
|
203497
203466
|
const reactIndexesPath = resolve20(reactDir, "indexes");
|
|
203498
203467
|
const { buildDir } = state.resolvedPaths;
|
|
203499
203468
|
const reactFiles = filesToRebuild.filter((file3) => detectFramework(file3, state.resolvedPaths) === "react");
|
|
203500
|
-
|
|
203469
|
+
const componentFiles = reactFiles.filter((f) => f.endsWith(".tsx") || f.endsWith(".jsx"));
|
|
203470
|
+
if (componentFiles.length > 0 && componentFiles.length === reactFiles.length) {
|
|
203501
203471
|
for (const file3 of reactFiles) {
|
|
203502
203472
|
state.fileHashes.set(resolve20(file3), computeFileHash(file3));
|
|
203503
203473
|
}
|
|
203504
|
-
const primaryFile =
|
|
203474
|
+
const primaryFile = componentFiles.find((f) => !f.replace(/\\/g, "/").includes("/pages/")) ?? componentFiles[0];
|
|
203505
203475
|
if (!primaryFile) {
|
|
203506
203476
|
onRebuildComplete({
|
|
203507
203477
|
hmrState: state,
|
|
@@ -203513,15 +203483,7 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, parseError
|
|
|
203513
203483
|
for (const file3 of reactFiles) {
|
|
203514
203484
|
invalidateModule2(file3);
|
|
203515
203485
|
}
|
|
203516
|
-
const
|
|
203517
|
-
let broadcastTarget = primaryFile;
|
|
203518
|
-
if (!isComponentFile) {
|
|
203519
|
-
const { findNearestComponent: findNearestComponent2 } = await Promise.resolve().then(() => (init_transformCache(), exports_transformCache));
|
|
203520
|
-
const nearest = findNearestComponent2(resolve20(primaryFile));
|
|
203521
|
-
if (nearest)
|
|
203522
|
-
broadcastTarget = nearest;
|
|
203523
|
-
}
|
|
203524
|
-
const pageModuleUrl = await getReactModuleUrl(broadcastTarget);
|
|
203486
|
+
const pageModuleUrl = await getReactModuleUrl(primaryFile);
|
|
203525
203487
|
if (pageModuleUrl) {
|
|
203526
203488
|
const serverDuration = Date.now() - startTime;
|
|
203527
203489
|
state.lastHmrPath = relative9(process.cwd(), primaryFile).replace(/\\/g, "/");
|
|
@@ -204903,5 +204865,5 @@ export {
|
|
|
204903
204865
|
build
|
|
204904
204866
|
};
|
|
204905
204867
|
|
|
204906
|
-
//# debugId=
|
|
204868
|
+
//# debugId=61FBA4F3A9C4EF4164756E2164756E21
|
|
204907
204869
|
//# sourceMappingURL=build.js.map
|