T
TanStack2mo ago
foreign-sapphire

SSR error on build in new project

I set up a completely new project using pnpm dlx create-tsrouter-app@latest my-app --template file-router --tailwind --add-ons shadcn and then ran pnpm run build in it. I am getting the following error:
error during build:
rollupOptions.input should not be an html file when building for SSR. Please specify a dedicated SSR entry.
error during build:
rollupOptions.input should not be an html file when building for SSR. Please specify a dedicated SSR entry.
As per this issue on github, I updated all of my dependencies to the latest versions at:
"@tanstack/nitro-v2-vite-plugin": "^1.133.19",
"@tanstack/react-devtools": "^0.7.8",
"@tanstack/react-router": "^1.133.27",
"@tanstack/react-router-devtools": "^1.133.27",
"@tanstack/router-plugin": "^1.133.27",
"@tanstack/nitro-v2-vite-plugin": "^1.133.19",
"@tanstack/react-devtools": "^0.7.8",
"@tanstack/react-router": "^1.133.27",
"@tanstack/react-router-devtools": "^1.133.27",
"@tanstack/router-plugin": "^1.133.27",
But I am still getting this error. For this project, I am not interested in SSR at all. What is the right way to just turn it off completely, or at least get around this issue.
GitHub
Failing to resolve solid-js/web · Issue #5420 · TanStack/router
Which project does this relate to? Router Describe the bug I cannot build my project anymore after version 1.132.51 as I'm receiving the following error: error during build: [vite]: Rollup fail...
5 Replies
sunny-green
sunny-green2mo ago
do you want just router or start?
foreign-sapphire
foreign-sapphireOP2mo ago
Just router
sunny-green
sunny-green2mo ago
remove nitroV2Plugin() @jherr we should only add nitroV2Plugin() to start projects, not router SPA ones
foreign-sapphire
foreign-sapphireOP2mo ago
That fixed it. I really appreciate it.
fascinating-indigo
fascinating-indigo2mo ago
Ok, I thought I had. I'll fix it.

Did you find this page helpful?