This commit is contained in:
2026-04-14 15:50:21 +01:00
parent f0aae8a8fa
commit d6f0a7962e
12 changed files with 202 additions and 20 deletions
@@ -70,6 +70,14 @@ export default async function genWebHTML({
const final_meta = _.merge(root_meta, page_meta);
// const public_envs = Object.keys(process.env).filter((e) =>
// e.startsWith(`NEXT_PUBLIC_`),
// );
const client_process = {
env: {},
};
let final_component = (
<html {...html_props}>
<head>
@@ -92,7 +100,7 @@ export default async function genWebHTML({
<script
dangerouslySetInnerHTML={{
__html: `window.${ClientWindowPagePropsName} = ${serializedProps}`,
__html: `window.${ClientWindowPagePropsName} = ${serializedProps};\nwindow.process = ${JSON.stringify(client_process)}`,
}}
data-bunext-head
/>
@@ -13,7 +13,9 @@ export default async function handleWebPages({
req,
}: Params): Promise<Response> {
try {
if (!isDevelopment()) {
const is_dev = isDevelopment();
if (!is_dev) {
const url = new URL(req.url);
const key = url.pathname + (url.search || "");