@absolutejs/absolute 0.19.0-beta.7 → 0.19.0-beta.8

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/build.js CHANGED
@@ -171235,6 +171235,29 @@ var isDev, extractBuildError = (logs, pass, label, frameworkNames, isIncremental
171235
171235
  setAngularVendorPaths(angularVendorPaths2);
171236
171236
  }
171237
171237
  const htmlScriptPlugin = hmr ? createHTMLScriptHMRPlugin(htmlDir, htmxDir) : undefined;
171238
+ const freshFilePlugin = isIncremental ? {
171239
+ name: "hmr-fresh-files",
171240
+ setup(pluginBuild) {
171241
+ pluginBuild.onLoad({ filter: /\.(tsx?|jsx?)$/ }, (args) => {
171242
+ try {
171243
+ const contents = readFileSync5(args.path, "utf-8");
171244
+ const ext = args.path.split(".").pop() ?? "tsx";
171245
+ const loaderMap = {
171246
+ js: "js",
171247
+ jsx: "jsx",
171248
+ ts: "ts",
171249
+ tsx: "tsx"
171250
+ };
171251
+ return {
171252
+ contents,
171253
+ loader: loaderMap[ext] ?? "tsx"
171254
+ };
171255
+ } catch {
171256
+ return;
171257
+ }
171258
+ });
171259
+ }
171260
+ } : undefined;
171238
171261
  const reactBuildConfig = reactClientEntryPoints.length > 0 ? {
171239
171262
  entrypoints: reactClientEntryPoints,
171240
171263
  ...vendorPaths ? { external: Object.keys(vendorPaths) } : {},
@@ -171243,6 +171266,7 @@ var isDev, extractBuildError = (logs, pass, label, frameworkNames, isIncremental
171243
171266
  naming: `[dir]/[name].[hash].[ext]`,
171244
171267
  outdir: buildPath,
171245
171268
  ...hmr ? { jsx: { development: true }, reactFastRefresh: true } : {},
171269
+ ...freshFilePlugin ? { plugins: [freshFilePlugin] } : {},
171246
171270
  root: clientRoot,
171247
171271
  splitting: true,
171248
171272
  target: "browser",
@@ -203674,5 +203698,5 @@ export {
203674
203698
  build
203675
203699
  };
203676
203700
 
203677
- //# debugId=E07CEF692C251FFC64756E2164756E21
203701
+ //# debugId=73EEB4B420C6458764756E2164756E21
203678
203702
  //# sourceMappingURL=build.js.map