Learn Vue JS course Learn Javascript and Vue JS Learn VueJS course Learn VueJS Tutorial

Static Site Generation with Nuxt.js

Get access to the most comprehensive Vue.js video library in the world. Over 300 video lessons including the newest Vue 3 features.

Prerendering Dynamic Routes

In this lesson, we learn how to prerender dynamic Nuxt routes.

The reason for why nuxt generate doesn't prerender dynamic routes out of the box, is that the framework doesn't know our dynamic content. We have to tell Nuxt about our dynamic content, for it to generate the static files.

Luckily, Nuxt provides us with an elegant solution to programmatically specify all our dynamic routes so we can generate the performant static files.

The Chrome extension used in this video is called JSON Viewer