Update HMR. Make it true HMR. Add URL to page server props
This commit is contained in:
@@ -13,10 +13,10 @@ export default async function grabPageBundledReactComponent({ file_path, root_fi
|
||||
tsx += `const props = JSON.parse("${server_res_json}")\n\n`;
|
||||
tsx += ` return (\n`;
|
||||
if (root_file) {
|
||||
tsx += ` <Root {...props}><Page {...props} /></Root>\n`;
|
||||
tsx += ` <Root suppressHydrationWarning={true} {...props}><Page {...props} /></Root>\n`;
|
||||
}
|
||||
else {
|
||||
tsx += ` <Page {...props} />\n`;
|
||||
tsx += ` <Page suppressHydrationWarning={true} {...props} />\n`;
|
||||
}
|
||||
tsx += ` )\n`;
|
||||
tsx += `}\n`;
|
||||
@@ -26,6 +26,7 @@ export default async function grabPageBundledReactComponent({ file_path, root_fi
|
||||
return {
|
||||
component,
|
||||
server_res,
|
||||
tsx,
|
||||
};
|
||||
}
|
||||
catch (error) {
|
||||
|
||||
Reference in New Issue
Block a user