NuxtN
Nuxt2y ago
9 replies
Thijs

Nuxt prerendering to deep

Hi can someone please help me? I want to deploy my nuxt with static deployment with npm run generate. But now my application generates a lot of routes this goes infinite. How can I fix this? My route structure is:

/cases/client-name

I use this structure:

pages/cases.vue
pages/cases/[...slug].vue

in my cases.vue is a NuxtPage, because my slug is in a sidebar.

See screenshots for clarification. So the problem is my prerender generates /cases/slug-1/another-slug/another-slug-1. But it needs to generate: /cases/slug-1/, /cases/slug-2.

How can I fix this?
image.png
image.png
image.png
Was this page helpful?