[SSG] No `200.html` is being rendered
See original GitHub issueEnvironment
RootDir: /sandbox Nuxt project info:
- Operating System:
Linux
- Node Version:
v14.18.1
- Nuxt Version:
3.0.0-rc.3
- Package Manager:
yarn@1.22.17
- Builder:
vite
- User Config:
-
- Runtime Modules:
-
- Build Modules:
-
Reproduction
- Open the sandbox (and possibly clone locally)
- Run
yarn generate
- See that a fallback file is missing
Describe the bug
When using target: 'static'
, I expected that a 200.html
(or differently named) fallback file is being rendered. Unfortunately, no such file is being generated at the moment.
Even with generate.fallback
set to true
or 200.html
, no file is present after the generation process.
Additional context
_Originally posted by @edwh in https://github.com/nuxt/framework/discussions/4967_
Logs
No response
Issue Analytics
- State:
- Created a year ago
- Reactions:2
- Comments:8 (3 by maintainers)
Top Results From Across the Web
HTML 5.1: 10. Rendering - W3C
An element is being rendered if it has any associated CSS layout boxes, SVG layout boxes, or some equivalent in other styling languages....
Read more >When to Choose SSR or SSG: A Guide to Page Rendering
In SSG, static HTML is rendered at build time from templates and content provided by the developer, then delivered upon request by the...
Read more >Next.js: Server-side Rendering vs. Static Generation - Vercel
With Static Generation (SSG), Next.js pre-renders the page into HTML on the server ahead of each request, such as at build time.
Read more >Server-Side Rendering - Vite
Pre-Rendering / SSG If the routes and the data needed for certain routes are known ahead of time, we can pre-render these routes...
Read more >Understanding static HTML export in Next.js - LogRocket Blog
js is renowned in the React world for being a great tool for dynamic applications because of its range of features and rendering...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
But this will render the
404.html
with the error layout “as is” and won’t allow SPA-like fallback. Which means solving “only” half of the issue.There’s also an issue with the types for the
fallback
property.According to the inline documentation the value should be
boolean | string
but it’s actually juststring
. You can reproduce this by changing the value on the sandbox OP provided.I looked for the types definition in the repo but I couldn’t find it. If anyone knows where they are, I’ll gladly make the change myself (if this is something that’s manually generated).