NuxtN
Nuxt12mo ago
Bootsmann

SSR false not working.

Im trying to create a preview site for my production site, I have ssr:false in my nuxt.config.ts and I've created the "~/app/spa-loading-template.html" file.

When i run "npm run generate" i get this output, it looks right:
(img 1)

But when i try to render a page it get 404 on my api routes. I only use "useFetch(<myApiRoute>)" to get data. Should i use another approach?

heres my code for an error:
(img 2).

Heres the code for the use fetch:
(img 3).

minimal reproduction: https://stackblitz.com/edit/github-exlt1jou?file=nuxt.config.ts
image.png
image.png
image.png
Was this page helpful?