Skip to content

Static Site Generation (SSG)

Entry #255 / 700 · Chapter 5 · 5.4 Logs, SSR vs CSR, migrations and i18n · Read in Chinese →
In one sentence

Producing every page as static HTML at build time, with no rendering at request time.

Analogy Mental model

Cooking the whole menu in advance and holding it warm. The guest is served instantly, and the dish is whatever was made this morning.

In practice What you actually do

Ideal for documentation, blogs and marketing pages where content changes on a schedule rather than per request. Build, deploy to a CDN, and the origin leaves the critical path entirely.

Where people get burned Pitfalls

Every content change requires a rebuild, which becomes painful at ten thousand pages or with minute-level updates. Incremental regeneration exists for exactly that middle ground.

This entry was written in English from the Chinese original, not machine-translated. Read the Chinese version →