@absolutejs/absolute 0.19.0-beta.737 → 0.19.0-beta.739
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/angular/index.js +5 -3
- package/dist/angular/index.js.map +3 -3
- package/dist/angular/server.js +5 -3
- package/dist/angular/server.js.map +3 -3
- package/dist/build.js +60 -3
- package/dist/build.js.map +4 -4
- package/dist/index.js +60 -3
- package/dist/index.js.map +4 -4
- package/package.json +1 -1
package/dist/build.js
CHANGED
|
@@ -44245,7 +44245,8 @@ var propProviders = Object.entries(pageProps).map(function(entry) {
|
|
|
44245
44245
|
// page module. Required so DI tokens that the component (or any service it
|
|
44246
44246
|
// injects) needs are available client-side too \u2014 without these, services
|
|
44247
44247
|
// that worked in SSR fail with NG0201 after hydration.
|
|
44248
|
-
var
|
|
44248
|
+
var maybePageProviders = Reflect.get(pageModule, 'providers');
|
|
44249
|
+
var pageProviders = Array.isArray(maybePageProviders) ? maybePageProviders : [];
|
|
44249
44250
|
|
|
44250
44251
|
// Re-Bootstrap HMR with View Transitions API
|
|
44251
44252
|
if (window.__ANGULAR_APP__) {
|
|
@@ -44316,7 +44317,8 @@ var propProviders = Object.entries(pageProps).map(function(entry) {
|
|
|
44316
44317
|
// page module. Required so DI tokens that the component (or any service it
|
|
44317
44318
|
// injects) needs are available client-side too \u2014 without these, services
|
|
44318
44319
|
// that worked in SSR fail with NG0201 after hydration.
|
|
44319
|
-
var
|
|
44320
|
+
var maybePageProviders = Reflect.get(pageModule, 'providers');
|
|
44321
|
+
var pageProviders = Array.isArray(maybePageProviders) ? maybePageProviders : [];
|
|
44320
44322
|
|
|
44321
44323
|
enableProdMode();
|
|
44322
44324
|
|
|
@@ -44822,6 +44824,61 @@ var escapeRegex2 = (str) => str.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), jsRewrit
|
|
|
44822
44824
|
} catch {}
|
|
44823
44825
|
}
|
|
44824
44826
|
await rewriteImports(allFiles, vendorPaths);
|
|
44827
|
+
await fixMissingReExportNamespaces(allFiles);
|
|
44828
|
+
}, fixMissingReExportNamespaces = async (files) => {
|
|
44829
|
+
const REEXPORT_PATTERN = /__reExport\(\s*[A-Za-z_$][\w$]*\s*,\s*([A-Za-z_$][\w$]*)\s*\)/g;
|
|
44830
|
+
await Promise.all(files.map(async (filePath) => {
|
|
44831
|
+
const content = await Bun.file(filePath).text();
|
|
44832
|
+
REEXPORT_PATTERN.lastIndex = 0;
|
|
44833
|
+
const missing = [];
|
|
44834
|
+
let match;
|
|
44835
|
+
while ((match = REEXPORT_PATTERN.exec(content)) !== null) {
|
|
44836
|
+
const ident = match[1];
|
|
44837
|
+
if (!ident)
|
|
44838
|
+
continue;
|
|
44839
|
+
const nsImportRe = new RegExp(`\\bimport\\s*\\*\\s*as\\s+${ident}\\s+from\\b`);
|
|
44840
|
+
if (nsImportRe.test(content))
|
|
44841
|
+
continue;
|
|
44842
|
+
const declRe = new RegExp(`\\b(?:const|let|var|function|class)\\s+${ident}\\b`);
|
|
44843
|
+
if (declRe.test(content))
|
|
44844
|
+
continue;
|
|
44845
|
+
const namedImportRe = new RegExp(`\\bimport\\s*\\{[^}]*\\b${ident}\\b[^}]*\\}\\s*from\\b`);
|
|
44846
|
+
if (namedImportRe.test(content))
|
|
44847
|
+
continue;
|
|
44848
|
+
const importPathRe = /from\s+["']([^"']+)["']/g;
|
|
44849
|
+
let pathMatch;
|
|
44850
|
+
let sourcePath;
|
|
44851
|
+
while ((pathMatch = importPathRe.exec(content)) !== null) {
|
|
44852
|
+
const p = pathMatch[1];
|
|
44853
|
+
if (!p)
|
|
44854
|
+
continue;
|
|
44855
|
+
const base = p.split("/").pop()?.replace(/\.[mc]?js$/, "");
|
|
44856
|
+
if (!base)
|
|
44857
|
+
continue;
|
|
44858
|
+
if (base === ident || base.endsWith(`_${ident}`)) {
|
|
44859
|
+
sourcePath = p;
|
|
44860
|
+
break;
|
|
44861
|
+
}
|
|
44862
|
+
}
|
|
44863
|
+
if (sourcePath) {
|
|
44864
|
+
missing.push({ ident, path: sourcePath });
|
|
44865
|
+
}
|
|
44866
|
+
}
|
|
44867
|
+
if (missing.length === 0)
|
|
44868
|
+
return;
|
|
44869
|
+
const seen = new Set;
|
|
44870
|
+
const unique = missing.filter((entry) => {
|
|
44871
|
+
if (seen.has(entry.ident))
|
|
44872
|
+
return false;
|
|
44873
|
+
seen.add(entry.ident);
|
|
44874
|
+
return true;
|
|
44875
|
+
});
|
|
44876
|
+
const inserts = unique.map((entry) => `import * as ${entry.ident} from "${entry.path}";`).join(`
|
|
44877
|
+
`);
|
|
44878
|
+
const patched = `${inserts}
|
|
44879
|
+
${content}`;
|
|
44880
|
+
await Bun.write(filePath, patched);
|
|
44881
|
+
}));
|
|
44825
44882
|
};
|
|
44826
44883
|
var init_rewriteImports = __esm(() => {
|
|
44827
44884
|
init_nativeRewrite();
|
|
@@ -49867,5 +49924,5 @@ export {
|
|
|
49867
49924
|
build
|
|
49868
49925
|
};
|
|
49869
49926
|
|
|
49870
|
-
//# debugId=
|
|
49927
|
+
//# debugId=E2CF1DC5C8E6083D64756E2164756E21
|
|
49871
49928
|
//# sourceMappingURL=build.js.map
|