@absolutejs/absolute 0.19.0-beta.32 → 0.19.0-beta.34
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 +16 -4
- package/dist/build.js.map +4 -4
- package/dist/index.js +311 -210
- package/dist/index.js.map +8 -7
- package/dist/react/index.js +88 -1
- package/dist/react/index.js.map +5 -4
- package/dist/src/dev/moduleServer.d.ts +3 -0
- package/dist/src/dev/ssrRenderer.d.ts +7 -0
- package/dist/src/dev/ssrWorker.d.ts +0 -0
- package/native/packages/darwin-arm64/package.json +1 -1
- package/native/packages/darwin-x64/package.json +1 -1
- package/native/packages/linux-arm64/package.json +1 -1
- package/native/packages/linux-x64/package.json +1 -1
- package/package.json +5 -5
package/dist/react/index.js
CHANGED
|
@@ -98,10 +98,97 @@ body{min-height:100vh;background:linear-gradient(135deg,rgba(15,23,42,0.98) 0%,r
|
|
|
98
98
|
</html>`;
|
|
99
99
|
};
|
|
100
100
|
|
|
101
|
+
// src/dev/ssrRenderer.ts
|
|
102
|
+
var exports_ssrRenderer = {};
|
|
103
|
+
__export(exports_ssrRenderer, {
|
|
104
|
+
renderInWorker: () => renderInWorker
|
|
105
|
+
});
|
|
106
|
+
import { resolve } from "path";
|
|
107
|
+
var worker = null, requestId = 0, pending, getWorker = () => {
|
|
108
|
+
if (worker)
|
|
109
|
+
return worker;
|
|
110
|
+
const workerPath = resolve(import.meta.dir, "ssrWorker.ts");
|
|
111
|
+
worker = new Worker(workerPath);
|
|
112
|
+
worker.onmessage = (event) => {
|
|
113
|
+
const { id, ok, html, error } = event.data;
|
|
114
|
+
const req = pending.get(id);
|
|
115
|
+
if (!req)
|
|
116
|
+
return;
|
|
117
|
+
pending.delete(id);
|
|
118
|
+
if (ok) {
|
|
119
|
+
req.resolve(html);
|
|
120
|
+
} else {
|
|
121
|
+
req.reject(new Error(error ?? "SSR render failed"));
|
|
122
|
+
}
|
|
123
|
+
};
|
|
124
|
+
worker.onerror = (event) => {
|
|
125
|
+
console.error("[SSR Worker] Error:", event);
|
|
126
|
+
for (const [id, req] of pending) {
|
|
127
|
+
req.reject(new Error("SSR worker crashed"));
|
|
128
|
+
pending.delete(id);
|
|
129
|
+
}
|
|
130
|
+
worker = null;
|
|
131
|
+
};
|
|
132
|
+
return worker;
|
|
133
|
+
}, renderInWorker = (request) => new Promise((resolvePromise, rejectPromise) => {
|
|
134
|
+
const id = ++requestId;
|
|
135
|
+
pending.set(id, {
|
|
136
|
+
reject: rejectPromise,
|
|
137
|
+
resolve: resolvePromise
|
|
138
|
+
});
|
|
139
|
+
const w = getWorker();
|
|
140
|
+
w.postMessage({
|
|
141
|
+
componentPath: resolve(request.componentPath),
|
|
142
|
+
id,
|
|
143
|
+
indexPath: request.indexPath,
|
|
144
|
+
props: request.props
|
|
145
|
+
});
|
|
146
|
+
});
|
|
147
|
+
var init_ssrRenderer = __esm(() => {
|
|
148
|
+
pending = new Map;
|
|
149
|
+
});
|
|
150
|
+
|
|
101
151
|
// src/react/pageHandler.ts
|
|
152
|
+
var isDev = process.env["NODE_ENV"] === "development";
|
|
153
|
+
var resolveComponentPath = (component) => {
|
|
154
|
+
const name = component.displayName ?? component.name;
|
|
155
|
+
if (!name)
|
|
156
|
+
return null;
|
|
157
|
+
const config = globalThis.__hmrDevResult?.hmrState?.config;
|
|
158
|
+
const reactDir = config?.reactDirectory;
|
|
159
|
+
if (!reactDir)
|
|
160
|
+
return null;
|
|
161
|
+
const { resolve: resolve2, join } = __require("path");
|
|
162
|
+
const { existsSync } = __require("fs");
|
|
163
|
+
const pagesDir = resolve2(reactDir, "pages");
|
|
164
|
+
const candidates = [
|
|
165
|
+
join(pagesDir, `${name}.tsx`),
|
|
166
|
+
join(pagesDir, `${name}.jsx`),
|
|
167
|
+
join(pagesDir, `${name}.ts`)
|
|
168
|
+
];
|
|
169
|
+
for (const candidate of candidates) {
|
|
170
|
+
if (existsSync(candidate))
|
|
171
|
+
return candidate;
|
|
172
|
+
}
|
|
173
|
+
return null;
|
|
174
|
+
};
|
|
102
175
|
var handleReactPageRequest = async (PageComponent, index, ...props) => {
|
|
103
176
|
try {
|
|
104
177
|
const [maybeProps] = props;
|
|
178
|
+
if (isDev) {
|
|
179
|
+
const componentPath = resolveComponentPath(PageComponent);
|
|
180
|
+
if (componentPath) {
|
|
181
|
+
const { renderInWorker: renderInWorker2 } = await Promise.resolve().then(() => (init_ssrRenderer(), exports_ssrRenderer));
|
|
182
|
+
const html = await renderInWorker2({
|
|
183
|
+
componentPath,
|
|
184
|
+
indexPath: index,
|
|
185
|
+
props: maybeProps
|
|
186
|
+
});
|
|
187
|
+
return new Response(html, {
|
|
188
|
+
headers: { "Content-Type": "text/html" }
|
|
189
|
+
});
|
|
190
|
+
}
|
|
191
|
+
}
|
|
105
192
|
const { createElement } = await import("react");
|
|
106
193
|
const { renderToReadableStream } = await import("react-dom/server");
|
|
107
194
|
const element = maybeProps !== undefined ? createElement(PageComponent, maybeProps) : createElement(PageComponent);
|
|
@@ -128,5 +215,5 @@ export {
|
|
|
128
215
|
handleReactPageRequest
|
|
129
216
|
};
|
|
130
217
|
|
|
131
|
-
//# debugId=
|
|
218
|
+
//# debugId=72487D134BE8505164756E2164756E21
|
|
132
219
|
//# sourceMappingURL=index.js.map
|
package/dist/react/index.js.map
CHANGED
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"version": 3,
|
|
3
|
-
"sources": ["../src/utils/ssrErrorPage.ts", "../src/react/pageHandler.ts"],
|
|
3
|
+
"sources": ["../src/utils/ssrErrorPage.ts", "../src/dev/ssrRenderer.ts", "../src/react/pageHandler.ts"],
|
|
4
4
|
"sourcesContent": [
|
|
5
5
|
"export const ssrErrorPage = (framework: string, error: unknown) => {\n\tconst frameworkColors: Record<string, string> = {\n\t\tangular: '#dd0031',\n\t\thtml: '#e34c26',\n\t\thtmx: '#1a365d',\n\t\treact: '#61dafb',\n\t\tsvelte: '#ff3e00',\n\t\tvue: '#42b883'\n\t};\n\n\tconst accent = frameworkColors[framework] ?? '#94a3b8';\n\tconst label = framework.charAt(0).toUpperCase() + framework.slice(1);\n\tconst message = error instanceof Error ? error.message : String(error);\n\n\treturn `<!DOCTYPE html>\n<html>\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=1\">\n<title>SSR Error - AbsoluteJS</title>\n<style>\n*{margin:0;padding:0;box-sizing:border-box}\nbody{min-height:100vh;background:linear-gradient(135deg,rgba(15,23,42,0.98) 0%,rgba(30,41,59,0.98) 100%);color:#e2e8f0;font-family:\"JetBrains Mono\",\"Fira Code\",ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;font-size:14px;line-height:1.6;display:flex;align-items:flex-start;justify-content:center;padding:32px}\n.card{max-width:720px;width:100%;background:rgba(30,41,59,0.6);border:1px solid rgba(71,85,105,0.5);border-radius:16px;box-shadow:0 25px 50px -12px rgba(0,0,0,0.5),0 0 0 1px rgba(255,255,255,0.05);overflow:hidden}\n.header{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:20px 24px;background:rgba(15,23,42,0.5);border-bottom:1px solid rgba(71,85,105,0.4)}\n.brand{font-weight:700;font-size:20px;color:#fff;letter-spacing:-0.02em}\n.badge{padding:5px 10px;border-radius:8px;font-size:12px;font-weight:600;background:${accent};color:#fff;opacity:0.95;box-shadow:0 2px 4px rgba(0,0,0,0.2)}\n.kind{color:#94a3b8;font-size:13px;font-weight:500}\n.content{padding:24px}\n.label{font-size:11px;font-weight:600;text-transform:uppercase;letter-spacing:0.08em;color:#94a3b8;margin-bottom:8px}\n.message{margin:0;padding:16px 20px;background:rgba(239,68,68,0.12);border:1px solid rgba(239,68,68,0.25);border-radius:10px;overflow-x:auto;white-space:pre-wrap;word-break:break-word;color:#fca5a5;font-size:13px;line-height:1.5}\n.hint{margin-top:20px;padding:12px 20px;background:rgba(71,85,105,0.3);border-radius:10px;border:1px solid rgba(71,85,105,0.4);color:#cbd5e1;font-size:13px}\n</style>\n</head>\n<body>\n<div class=\"card\">\n<div class=\"header\">\n<div style=\"display:flex;align-items:center;gap:12px\">\n<span class=\"brand\">AbsoluteJS</span>\n<span class=\"badge\">${label}</span>\n</div>\n<span class=\"kind\">Server Render Error</span>\n</div>\n<div class=\"content\">\n<div class=\"label\">What went wrong</div>\n<pre class=\"message\">${message.replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>')}</pre>\n<div class=\"hint\">A component threw during server-side rendering. Check the terminal for the full stack trace.</div>\n</div>\n</div>\n</body>\n</html>`;\n};\n",
|
|
6
|
-
"import
|
|
6
|
+
"import { resolve } from 'node:path';\n\ntype RenderRequest = {\n\tcomponentPath: string;\n\tindexPath: string;\n\tprops?: Record<string, unknown>;\n};\n\ntype PendingRender = {\n\tresolve: (html: string) => void;\n\treject: (error: Error) => void;\n};\n\nlet worker: Worker | null = null;\nlet requestId = 0;\nconst pending = new Map<number, PendingRender>();\n\nconst getWorker = () => {\n\tif (worker) return worker;\n\n\tconst workerPath = resolve(import.meta.dir, 'ssrWorker.ts');\n\tworker = new Worker(workerPath);\n\n\tworker.onmessage = (event) => {\n\t\tconst { id, ok, html, error } = event.data;\n\t\tconst req = pending.get(id);\n\t\tif (!req) return;\n\t\tpending.delete(id);\n\n\t\tif (ok) {\n\t\t\treq.resolve(html);\n\t\t} else {\n\t\t\treq.reject(new Error(error ?? 'SSR render failed'));\n\t\t}\n\t};\n\n\tworker.onerror = (event) => {\n\t\tconsole.error('[SSR Worker] Error:', event);\n\t\t// Reject all pending\n\t\tfor (const [id, req] of pending) {\n\t\t\treq.reject(new Error('SSR worker crashed'));\n\t\t\tpending.delete(id);\n\t\t}\n\t\tworker = null;\n\t};\n\n\treturn worker;\n};\n\nexport const renderInWorker = (request: RenderRequest) =>\n\tnew Promise<string>((resolvePromise, rejectPromise) => {\n\t\tconst id = ++requestId;\n\t\tpending.set(id, {\n\t\t\treject: rejectPromise,\n\t\t\tresolve: resolvePromise\n\t\t});\n\n\t\tconst w = getWorker();\n\t\tw.postMessage({\n\t\t\tcomponentPath: resolve(request.componentPath),\n\t\t\tid,\n\t\t\tindexPath: request.indexPath,\n\t\t\tprops: request.props\n\t\t});\n\t});\n",
|
|
7
|
+
"import type { ComponentType as ReactComponent } from 'react';\nimport { ssrErrorPage } from '../utils/ssrErrorPage';\n\nconst isDev = process.env['NODE_ENV'] === 'development';\n\n// In dev mode, resolve the component's source path from its name\n// so we can render in a worker (outside bun --hot's module graph)\nconst resolveComponentPath = (component: ReactComponent<Record<string, unknown>>) => {\n\tconst name = component.displayName ?? component.name;\n\tif (!name) return null;\n\n\tconst config = globalThis.__hmrDevResult?.hmrState?.config;\n\tconst reactDir = config?.reactDirectory;\n\tif (!reactDir) return null;\n\n\tconst { resolve, join } = require('node:path');\n\tconst { existsSync } = require('node:fs');\n\tconst pagesDir = resolve(reactDir, 'pages');\n\tconst candidates = [\n\t\tjoin(pagesDir, `${name}.tsx`),\n\t\tjoin(pagesDir, `${name}.jsx`),\n\t\tjoin(pagesDir, `${name}.ts`)\n\t];\n\n\tfor (const candidate of candidates) {\n\t\tif (existsSync(candidate)) return candidate;\n\t}\n\n\treturn null;\n};\n\nexport const handleReactPageRequest = async <\n\tProps extends Record<string, unknown> = Record<never, never>\n>(\n\tPageComponent: ReactComponent<Props>,\n\tindex: string,\n\t...props: keyof Props extends never ? [] : [props: NoInfer<Props>]\n) => {\n\ttry {\n\t\tconst [maybeProps] = props;\n\n\t\t// In dev mode, render in a worker to avoid polluting\n\t\t// bun --hot's module graph with frontend imports\n\t\tif (isDev) {\n\t\t\tconst componentPath = resolveComponentPath(\n\t\t\t\tPageComponent as ReactComponent<Record<string, unknown>>\n\t\t\t);\n\t\t\tif (componentPath) {\n\t\t\t\tconst { renderInWorker } = await import(\n\t\t\t\t\t'../dev/ssrRenderer'\n\t\t\t\t);\n\t\t\t\tconst html = await renderInWorker({\n\t\t\t\t\tcomponentPath,\n\t\t\t\t\tindexPath: index,\n\t\t\t\t\tprops: maybeProps as Record<string, unknown> | undefined\n\t\t\t\t});\n\n\t\t\t\treturn new Response(html, {\n\t\t\t\t\theaders: { 'Content-Type': 'text/html' }\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\t// Production path (or fallback if component path not found)\n\t\tconst { createElement } = await import('react');\n\t\tconst { renderToReadableStream } = await import('react-dom/server');\n\n\t\tconst element =\n\t\t\tmaybeProps !== undefined\n\t\t\t\t? createElement(PageComponent, maybeProps)\n\t\t\t\t: createElement(PageComponent);\n\n\t\tconst propsScript = maybeProps\n\t\t\t? `window.__INITIAL_PROPS__=${JSON.stringify(maybeProps)}`\n\t\t\t: '';\n\n\t\tconst stream = await renderToReadableStream(element, {\n\t\t\tbootstrapModules: [index],\n\t\t\tbootstrapScriptContent: propsScript || undefined,\n\t\t\tonError(error: unknown) {\n\t\t\t\tconsole.error('[SSR] React streaming error:', error);\n\t\t\t}\n\t\t});\n\n\t\treturn new Response(stream, {\n\t\t\theaders: { 'Content-Type': 'text/html' }\n\t\t});\n\t} catch (error) {\n\t\tconsole.error('[SSR] React render error:', error);\n\n\t\treturn new Response(ssrErrorPage('react', error), {\n\t\t\theaders: { 'Content-Type': 'text/html' },\n\t\t\tstatus: 500\n\t\t});\n\t}\n};\n"
|
|
7
8
|
],
|
|
8
|
-
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAAa,eAAe,CAAC,WAAmB,UAAmB;AAAA,EAClE,MAAM,kBAA0C;AAAA,IAC/C,SAAS;AAAA,IACT,MAAM;AAAA,IACN,MAAM;AAAA,IACN,OAAO;AAAA,IACP,QAAQ;AAAA,IACR,KAAK;AAAA,EACN;AAAA,EAEA,MAAM,SAAS,gBAAgB,cAAc;AAAA,EAC7C,MAAM,QAAQ,UAAU,OAAO,CAAC,EAAE,YAAY,IAAI,UAAU,MAAM,CAAC;AAAA,EACnE,MAAM,UAAU,iBAAiB,QAAQ,MAAM,UA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AAA,MACvC,OAAO,CAAC,OAAgB;AAAA,QACvB,QAAQ,MAAM,gCAAgC,KAAK;AAAA;AAAA,IAErD,CAAC;AAAA,IAED,OAAO,IAAI,SAAS,QAAQ;AAAA,MAC3B,SAAS,EAAE,gBAAgB,YAAY;AAAA,IACxC,CAAC;AAAA,IACA,OAAO,OAAO;AAAA,IACf,QAAQ,MAAM,6BAA6B,KAAK;AAAA,IAEhD,OAAO,IAAI,SAAS,aAAa,SAAS,KAAK,GAAG;AAAA,MACjD,SAAS,EAAE,gBAAgB,YAAY;AAAA,MACvC,QAAQ;AAAA,IACT,CAAC;AAAA;AAAA;",
|
|
10
|
+
"debugId": "72487D134BE8505164756E2164756E21",
|
|
10
11
|
"names": []
|
|
11
12
|
}
|
|
@@ -4,5 +4,8 @@ type ModuleServerConfig = {
|
|
|
4
4
|
};
|
|
5
5
|
export declare const createModuleServer: (config: ModuleServerConfig) => (pathname: string) => Promise<Response | undefined>;
|
|
6
6
|
export declare const invalidateModule: (filePath: string) => void;
|
|
7
|
+
export declare const warmCache: (pathname: string) => void;
|
|
8
|
+
declare let globalModuleServer: ((pathname: string) => Promise<Response | undefined> | Response | undefined) | null;
|
|
9
|
+
export declare const setGlobalModuleServer: (handler: typeof globalModuleServer) => void;
|
|
7
10
|
export declare const SRC_URL_PREFIX = "/@src/";
|
|
8
11
|
export {};
|
|
File without changes
|
package/package.json
CHANGED
|
@@ -138,10 +138,10 @@
|
|
|
138
138
|
}
|
|
139
139
|
},
|
|
140
140
|
"optionalDependencies": {
|
|
141
|
-
"@absolutejs/native-darwin-arm64": "0.19.0-beta.
|
|
142
|
-
"@absolutejs/native-darwin-x64": "0.19.0-beta.
|
|
143
|
-
"@absolutejs/native-linux-arm64": "0.19.0-beta.
|
|
144
|
-
"@absolutejs/native-linux-x64": "0.19.0-beta.
|
|
141
|
+
"@absolutejs/native-darwin-arm64": "0.19.0-beta.34",
|
|
142
|
+
"@absolutejs/native-darwin-x64": "0.19.0-beta.34",
|
|
143
|
+
"@absolutejs/native-linux-arm64": "0.19.0-beta.34",
|
|
144
|
+
"@absolutejs/native-linux-x64": "0.19.0-beta.34"
|
|
145
145
|
},
|
|
146
146
|
"repository": {
|
|
147
147
|
"type": "git",
|
|
@@ -162,5 +162,5 @@
|
|
|
162
162
|
"typecheck": "bun run vue-tsc --noEmit"
|
|
163
163
|
},
|
|
164
164
|
"types": "./dist/src/index.d.ts",
|
|
165
|
-
"version": "0.19.0-beta.
|
|
165
|
+
"version": "0.19.0-beta.34"
|
|
166
166
|
}
|