Vim bindings demo
Note: The CodeMirror vim bindings are maintained in the codemirror-vim repository, not this project. The file is still included in the distribution for backwards compatibility.
Key buffer: 
Vim mode: 
The vim keybindings are enabled by including keymap/vim.js and setting the
keyMap option to vim.
Features
- All common motions and operators, including text objects
 - Operator motion orthogonality
 - Visual mode - characterwise, linewise, blockwise
 - Full macro support (q, @)
 - Incremental highlighted search (/, ?, #, *, g#, g*)
 - Search/replace with confirm (:substitute, :%s)
 - Search history
 - Jump lists (Ctrl-o, Ctrl-i)
 - Key/command mapping with API (:map, :nmap, :vmap)
 - Sort (:sort)
 - Marks (`, ')
 - :global
 - Insert mode behaves identical to base CodeMirror
 - Cross-buffer yank/paste
 
For the full list of key mappings and Ex commands, refer to the
defaultKeymap and defaultExCommandMap at the
top of keymap/vim.js.
Note that while the vim mode tries to emulate the most useful features of vim as faithfully as possible, it does not strive to become a complete vim implementation
