From 065b0c90d8f85ded8d71a9852820faccee01200a Mon Sep 17 00:00:00 2001 From: Hiroshi Ogawa Date: Fri, 15 Nov 2024 17:08:27 +0900 Subject: [PATCH] wip: debug --- viteroll/examples/ssr-simple/src/entry-server.tsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/viteroll/examples/ssr-simple/src/entry-server.tsx b/viteroll/examples/ssr-simple/src/entry-server.tsx index e93fdc6..5deafaf 100644 --- a/viteroll/examples/ssr-simple/src/entry-server.tsx +++ b/viteroll/examples/ssr-simple/src/entry-server.tsx @@ -4,7 +4,9 @@ const handler: Connect.SimpleHandleFunction = (req, res) => { const url = new URL(req.url ?? "/", "https://vite.dev"); console.log(`[SSR] ${req.method} ${url.pathname}`); if (url.pathname === "/crash-ssr") { - throw new Error("crash-ssr"); + const error = new Error("crash-ssr"); + console.error(error); + throw error; } res.setHeader("content-type", "text/html"); // TODO: transformIndexHtml? @@ -15,7 +17,8 @@ const handler: Connect.SimpleHandleFunction = (req, res) => { - Test SSR +

Rolldown SSR

+ /crash-ssr `);