Next.js · Middle · Question 48 of 75
How is page data updated after an action if revalidateTag(tag, 'max') is used?
- ✓Correct answer: The visitor gets the old data, and fresh data is generated in the background
- 2The page instantly reloads for all users
- 3The data updates only after the project is rebuilt
Explanation
The 'max' profile gives stale-while-revalidate semantics: the entry is marked stale, the first request gets the old version and triggers regeneration. If the author of the change should see the result immediately, use updateTag in a Server Action.