Skip to content

docs: draftMode alignment#92794

Open
icyJoseph wants to merge 2 commits intocanaryfrom
worktree-update-draft-mode-docs
Open

docs: draftMode alignment#92794
icyJoseph wants to merge 2 commits intocanaryfrom
worktree-update-draft-mode-docs

Conversation

@icyJoseph
Copy link
Copy Markdown
Member

@icyJoseph icyJoseph commented Apr 14, 2026

@nextjs-bot nextjs-bot added created-by: Next.js DevEx team PRs by the DX team. Documentation Related to Next.js' official documentation. labels Apr 14, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Apr 14, 2026

All broken links are now fixed, thank you!

@icyJoseph icyJoseph force-pushed the worktree-update-draft-mode-docs branch from 9ca1126 to 22bdd1d Compare April 14, 2026 18:45
Copy link
Copy Markdown
Contributor

@gnoff gnoff left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved with nits

cursor bot pushed a commit to gaojude/next.js that referenced this pull request Apr 14, 2026
Frames PR vercel#92794 (docs: draftMode alignment) as an agent eval.

Tests whether a coding agent correctly wires draftMode() inside a
"use cache" scope:
- Uses "use cache" directive for caching
- Reads draftMode().isEnabled inside the cache boundary (async)
- Conditionally fetches draft vs published content
- Does NOT call enable()/disable() inside cache scope
- Does NOT call cookies()/headers() inside cache scope
- Enables useCache or cacheComponents in next.config
- Avoids deprecated caching patterns
@icyJoseph icyJoseph marked this pull request as ready for review April 14, 2026 23:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

created-by: Next.js DevEx team PRs by the DX team. Documentation Related to Next.js' official documentation.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants