Skip to content
| Marketplace
Sign in
Visual Studio Code>Other>Vim Normal Cursor FixNew to Visual Studio Code? Get it now.
Vim Normal Cursor Fix

Vim Normal Cursor Fix

cosmicethics

|
1 install
| (0) | Free
Fix VSCodeVim normal-mode `h`/`l`/`w`/`b`/`e`/`$`/`j`/`k` mappings, so block cursors are corrected around inlay hints.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Vim Normal Cursor Fix

Provides cursor commands intended for VSCodeVim normal-mode h/l/w/b/e/$/j/k mappings. The commands still call VS Code's built-in cursor movement so block cursors are corrected around inlay hints.

Usage

"vim.normalModeKeyBindingsNonRecursive": [
  {
    "before": ["h"],
    "commands": ["vimNormalCursorFix.cursorLeft"]
  },
  {
    "before": ["l"],
    "commands": ["vimNormalCursorFix.cursorRight"]
  },
  {
    "before": ["w"],
    "commands": ["vimNormalCursorFix.cursorWordStartRight"]
  },
  {
    "before": ["e"],
    "commands": ["vimNormalCursorFix.cursorWordEndRight"]
  },
  {
    "before": ["b"],
    "commands": ["vimNormalCursorFix.cursorWordStartLeft"]
  },
  {
    "before": ["$"],
    "commands": ["vimNormalCursorFix.cursorLineEnd"]
  },
  {
    "before": ["j"],
    "commands": ["vimNormalCursorFix.cursorDown"]
  },
  {
    "before": ["k"],
    "commands": ["vimNormalCursorFix.cursorUp"]
  }
]

The commands clamp cursor movement to the current line:

  • vimNormalCursorFix.cursorLeft stops at column 0.
  • vimNormalCursorFix.cursorRight stops at the last normal-mode cursor position of the current line.
  • vimNormalCursorFix.cursorWordStartRight and vimNormalCursorFix.cursorWordStartLeft keep VS Code's cross-line word motion and clamp line-end positions back to the last character.
  • vimNormalCursorFix.cursorWordEndRight implements a Vim-style e motion, then applies the same inlay-hints cursor correction.
  • vimNormalCursorFix.cursorLineEnd, cursorDown, and cursorUp clamp to the last normal-mode character when needed. At line end, they move to the previous character and reuse the fixed cursorRight logic instead of a plain right-left nudge, which would overshoot at EOL.

Use the extension command names in VSCodeVim settings. Mapping directly to cursorLeft or cursorRight bypasses this extension.

Development

npm install
npm run compile
npm run package

npm run package builds vim-normal-cursor-fix-x.x.x.vsix.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
  • Your Privacy Choices
  • Consumer Health Privacy
© 2026 Microsoft