CodeZettaInterview Hub

Next.js · Metadata · Junior · Comparison

When do you use generateMetadata vs static metadata?

Short Interview Answer

Static for fixed pages; generateMetadata when title/OG depends on fetched content.

Detailed Explanation

Await data carefully; avoid slowing TTFB with unnecessary waterfalls. Cache underlying fetches.

Did you know this answer?