VS Code: Add setting to disable auto-navigation to file on Edit/Write
Problem
When Claude Code makes edits via the Edit or Write tool in VS Code, the extension automatically opens a diff tab and navigates focus away from the chat panel. This forces users to manually navigate back to the chat to continue the conversation.
For users working in the VS Code chat panel, this creates a disruptive workflow — every edit causes a context switch. When Claude makes multiple edits in sequence, the user has to repeatedly navigate back.
Proposed Solution
Add a VS Code extension setting (e.g., claudeCode.autoRevealEdits) that controls whether diff tabs are automatically opened/focused when edits are made.
Options:
true(default, current behavior): Open diff tab on every editfalse: Don't auto-open diff tabs; user can review diffs on demand
The relevant code path is the vscode.diff command execution with {preview: false, preserveFocus: true} options. When the setting is false, this command would simply be skipped.
Alternatives Considered
preserveFocus: truealone isn't enough — the tab still appears and steals visual attention even if focus is preserved- Pinning the chat tab — workaround, not a fix
Use Case
Power users who trust Claude's edits and want to stay in the chat flow, reviewing diffs only when needed (e.g., via source control panel or git diff).
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗