Vim mode: reset to insert mode on new prompt

Resolved 💬 5 comments Opened Mar 21, 2026 by 1-fares Closed Apr 18, 2026

Problem

When vim mode is enabled, the editor mode persists across prompts. If you switch to normal mode to review or edit your text before submitting, the next prompt also starts in normal mode.

This creates a usability issue: a new empty prompt has no text to navigate, yank, delete, or operate on. Normal mode on an empty input is a dead state — the only useful action is switching to insert mode. And you can't just reflexively press i either, because if the previous prompt was submitted from insert mode, you'd type a literal "i" that you then have to delete.

Expected behavior

Each new prompt should start in insert mode regardless of what mode the previous prompt was submitted in. A fresh empty input is always an "insert" context — there is nothing to do in normal mode.

Suggested solution

Either:

  • Always reset to insert mode when a new prompt begins (sensible default, matches how most vim-enabled inputs work — e.g., vim-mode in shells like zsh with vi-mode resets on each new prompt line)
  • Add a configuration option (e.g., vimResetModeOnSubmit: true) for users who prefer the current behavior

View original on GitHub ↗

This issue has 5 comments on GitHub. Read the full discussion on GitHub ↗