@absolutejs/absolute 0.19.0-beta.104 → 0.19.0-beta.105
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/dist/build.js +7 -10
- package/dist/build.js.map +4 -4
- package/dist/index.js +7 -10
- package/dist/index.js.map +4 -4
- package/package.json +1 -1
package/dist/build.js
CHANGED
|
@@ -171562,16 +171562,14 @@ var isDev, extractBuildError = (logs, pass, label, frameworkNames, isIncremental
|
|
|
171562
171562
|
const reactClientLogs = reactClientResult?.logs ?? [];
|
|
171563
171563
|
const reactClientOutputs = reactClientResult?.outputs ?? [];
|
|
171564
171564
|
if (hmr && reactClientOutputs.length > 0) {
|
|
171565
|
-
const
|
|
171565
|
+
const REFRESH_NOOP = "window.$RefreshReg$||(window.$RefreshReg$=function(){});window.$RefreshSig$||(window.$RefreshSig$=function(){return function(t){return t}});";
|
|
171566
171566
|
for (const output of reactClientOutputs) {
|
|
171567
171567
|
if (output.kind !== "entry-point")
|
|
171568
171568
|
continue;
|
|
171569
171569
|
try {
|
|
171570
171570
|
const content = await Bun.file(output.path).text();
|
|
171571
|
-
if (
|
|
171572
|
-
|
|
171573
|
-
const stripped = content.replace(REFRESH_NOOP_RE, "");
|
|
171574
|
-
writeFileSync3(output.path, stripped);
|
|
171571
|
+
if (content.includes(REFRESH_NOOP)) {
|
|
171572
|
+
writeFileSync3(output.path, content.replace(REFRESH_NOOP, "").replace(/^\n/, ""));
|
|
171575
171573
|
}
|
|
171576
171574
|
} catch {}
|
|
171577
171575
|
}
|
|
@@ -203500,15 +203498,14 @@ var moduleServerPromise, getModuleServer = () => moduleServerPromise, parseError
|
|
|
203500
203498
|
await rewriteReactImports2(clientResult.outputs.map((art) => art.path), vendorPaths);
|
|
203501
203499
|
}
|
|
203502
203500
|
const { readFileSync: readFs, writeFileSync: writeFs } = await import("fs");
|
|
203503
|
-
const
|
|
203501
|
+
const REFRESH_NOOP = "window.$RefreshReg$||(window.$RefreshReg$=function(){});window.$RefreshSig$||(window.$RefreshSig$=function(){return function(t){return t}});";
|
|
203504
203502
|
for (const output of clientResult.outputs) {
|
|
203505
203503
|
if (output.kind !== "entry-point")
|
|
203506
203504
|
continue;
|
|
203507
203505
|
try {
|
|
203508
203506
|
const content = readFs(output.path, "utf-8");
|
|
203509
|
-
if (
|
|
203510
|
-
|
|
203511
|
-
writeFs(output.path, content.replace(NOOP_RE, ""));
|
|
203507
|
+
if (content.includes(REFRESH_NOOP)) {
|
|
203508
|
+
writeFs(output.path, content.replace(REFRESH_NOOP, "").replace(/^\n/, ""));
|
|
203512
203509
|
}
|
|
203513
203510
|
} catch {}
|
|
203514
203511
|
}
|
|
@@ -204935,5 +204932,5 @@ export {
|
|
|
204935
204932
|
build
|
|
204936
204933
|
};
|
|
204937
204934
|
|
|
204938
|
-
//# debugId=
|
|
204935
|
+
//# debugId=0D1F63D570A5C7DA64756E2164756E21
|
|
204939
204936
|
//# sourceMappingURL=build.js.map
|