Skip to main content
Career & GrowthTools & Productivity

Practical Vim for Modern Developers

You don't need to live in Vim to benefit from it. Learn the motions and mental model that make editing code dramatically faster.

Mbeah Essilfie

Mbeah Essilfie

April 20, 2026 at 06:04 AM

8 min read 1368 views
Practical Vim for Modern Developers

You Don't Have to Switch Editors

Vim isn't an editor — it's an editing language. Learn the motions and use them everywhere: VS Code (Vim extension), JetBrains (IdeaVim), or the terminal.

The Mental Model

Vim commands are verb + noun:

  • d (delete) + w (word) = delete a word
  • c (change) + i" (inside quotes) = change text inside quotes
  • y (yank/copy) + ap (a paragraph) = copy a paragraph

Essential Motions (The Nouns)

w/b     → next/previous word
e       → end of word
0/$     → start/end of line
gg/G    → start/end of file
f{char} → jump to character on line
%       → matching bracket
/{text} → search forward

Essential Operators (The Verbs)

d → delete
c → change (delete + enter insert mode)
y → yank (copy)
v → visual select
> → indent
< → unindent

Text Objects (The Precision Tools)

iw → "inner word"        (just the word)
aw → "a word"            (word + surrounding space)
i" → inside quotes
i( → inside parentheses
it → inside HTML tag
ip → inner paragraph
Text objects are Vim's superpower. ci" (change inside quotes) works regardless of where your cursor is within the quotes. No need to select first.

Recipes for Daily Coding

ci'     → Change string contents: 'hello' → '|'
da(     → Delete function args: fn(a, b) → fn
yap     → Copy entire paragraph
V5j>    → Select 6 lines and indent
*       → Search for word under cursor
cgn     → Change next search match (then . to repeat)

Practical Workflow: Rename Variable

/oldName    → Search for the variable
cgn         → Change the current match
newName     → Type the new name
<Esc>       → Back to normal mode
.           → Repeat on next match (press n to skip)

Multi-Cursor Alternative: Macros

qa          → Start recording macro into register 'a'
(edits)     → Make your changes on one line
q           → Stop recording
@a          → Replay the macro
10@a        → Replay 10 more times

VS Code + Vim Config

// settings.json
{
  "vim.leader": "<space>",
  "vim.useSystemClipboard": true,
  "vim.normalModeKeyBindings": [
    { "before": ["<leader>", "w"], "commands": ["workbench.action.files.save"] },
    { "before": ["<leader>", "f"], "commands": ["editor.action.formatDocument"] },
    { "before": ["<leader>", "p"], "commands": ["workbench.action.quickOpen"] }
  ]
}

Learning Path

  1. Week 1: hjkl navigation, i/a to insert, dd/yy/p basics
  2. Week 2: w/b/e word motions, f/t character jumps
  3. Week 3: Text objects (ci", di(, yap)
  4. Week 4: Macros, visual mode, registers

You'll be slower for 2 weeks. Then faster than ever after that. The ROI compounds over your entire career.

DevOpsPython
Mbeah Essilfie

Written by Mbeah Essilfie

Fullstack Software Developer

Read next

The Complete Guide to Vue 3 Composables
12 min read

The Complete Guide to Vue 3 Composables

Understand the power of Vue 3's Composition API through practical, real-world composable patterns that you can use today.

Mbeah EssilfieMbeah Essilfie
986