terminal
Course Description
Fly through code faster than you thought possible using VIM! You’ll learn the basics of editing and even know how to exit VIM. Go deeper with navigation, macros, registers, find, and replaces. Then edit your vimrc plugins along with quickfix lists. Lastly, see ThePrimeagen demonstrate his ideal VIM workflow.
This course and others like it are available as part of our Frontend Masters video subscription.
Preview
CloseWhat They're Saying
It was the best purchase I have made so far. I enjoy learning VIM so much with ThePrimeagen. This guy is incredible. My experience with Frontend Masters so far has been fantastic.
![Ivan A.](https://senjaio.b-cdn.net/public/media/4319a4e6-3f36-45a3-b48a-4bf814465143_51b246e0-56f0-496c-b736-810161785b71_ivan.jpeg)
Ivan A.
Ivan A.
I watched the ThePrimeagen’s vim videos on FrontendMasters. Now I use VS Code and Zed in vim mode.
![Babátúndé Adéyẹmí](https://pbs.twimg.com/profile_images/1770400981940871168/QRQYP44-.jpg)
Babátúndé Adéyẹmí
codingpop
ThePrimeagen pulled me in to the dark side. I'm embarking on the journey to learn VIM 🫢. This is what happens if you watch Frontend Masters instead of Netfilx.
![Juris Zemītis](https://pbs.twimg.com/profile_images/1598405487552331778/Gs10YqqY.jpg)
Juris Zemītis
ZemitisJuris
Learn Straight from the Experts Who Shape the Modern Web
Your Path to Senior Developer and Beyond
- 200+ In-depth courses
- 18 Learning Paths
- Industry Leading Experts
- Live Interactive Workshops
Table of Contents
Introduction
Section Duration: 34 minutes
- ThePrimeagen provides a brief overview of the course, briefly introduces ED, and discusses the history of vim. The program that predates vim is vi which was written by Bill Joy for small systems on slow internet connections.
- ThePrimeagen discusses some personal history with getting into using vim, what types of content is on their Youtube and Twitch channels, what type of person should take this course, and course prerequisites. Different types of vim are also briefly covered in this segment.
- ThePrimeagen discusses some vim terminology including files, buffers, windows, splits, and tabs. Other terminology including line numbers, current line, cursor, sign column, current mode, and the color column are briefly covered in this segment.
- ThePrimeagen demonstrates how to access the help menu, discusses abbreviations that will be used in the course, and gives an overview of the course. A student's question regarding what types of development can be done in vim is also covered in this segment.
Opening VIM
Section Duration: 40 minutes
- ThePrimeagen demonstrates some basic movements including how to open vim, close vim, and switch modes. The different modes of vim including Normal, Insert, Visual, and Visual Line are also briefly covered in this segment.
- ThePrimeagen demonstrates basic navigation including moving the cursor up, down, left, and right, recentering the screen, hopping forward by word, and hopping backwards. How to delete a single character is also covered in this segment
- ThePrimeagen demonstrates how to delete a line, undo the last action, yank a line, paste, and the register is briefly discussed. Using visual mode to highlight code and use combinations of commands is also covered in this segment.
- ThePrimeagen demonstrates how to go into insert mode, insert to the left and right of the cursor, and inserting new lines. There is a brief overview of all motions covered so far at the end of the segment.
Customization
Section Duration: 1 hour
- ThePrimeagen demonstrates how to execute commands including setting auto scrolling, deleting multiple lines, setting line numbers. Setting relative line numbers will display line numbers that are relative to where the cursor is currently located.
- ThePrimeagen walks through creating persisting custom settings by saving commands to a vimrc that will automatically execute when a file is opened in vim. A brief overview of previous motions and how to access a list of available options is also covered in this segment.
- ThePrimeagen demonstrates how to set vim's color scheme from a list of preset options. The chosen color scheme can also be saved for later in vimrc.
- ThePrimeagen demonstrates how to navigate vim's default file system plugin NetRW. A student's question regarding how to navigate between the splits is also covered in this segment. Ctrl + w will access window mode and allow window specific commands to be executed.
- ThePrimeagen demonstrates how to name remapped keys, set specific modes that will use the remap, and how to set what will be executed by the remapped key.
- ThePrimeagen demonstrates how to use the edit command to open and navigate files in vim.
- ThePrimeagen briefly previews a more customized view of vim which uses the telescope plugin and demonstrates how to navigate files using marks. Marks will bookmark files for quick global or file level access.
- ThePrimeagen does a brief recap of files and navigation, demonstrates how to quick switch to an alternate file, and how to use a jumplist. The jumplist displays a sequential list of previously accessed files that can be navigated through using Ctrl + o to go backwards and Ctrl + i to go forwards.
- ThePrimeagen discusses previously covered navigation, vimRC, and file navigation. Student questions regarding how to change cursor thickness and multi cursors are also covered in this segment.
Plugins
Section Duration: 59 minutes
- ThePrimeagen walks through installing vim-plug as a plugin manager and fzf.vim as a fuzzy finder. Both of the plugins installed are open source Github repositories. A brief recap of remapping shortcuts is also covered in this segment.
- ThePrimeagen demonstrates how to install ayu-vim as a color scheme and briefly mentions a few other popular color schemes including gruvbox and dracula.
- ThePrimeagen demonstrates how to search for, create, and navigate a quickfix list using ripgrep and fzf. How to search for and create a quickfix list with grep is also covered in this segment.
- ThePrimeagen live codes searching for and ordering the course lessons using grep and getqflist in lua. The example in this segment demonstrates the ability to create custom plugins to edit quickfix lists.
- ThePrimeagen demonstrates how to search in vim, navigate, highlight, and replace the results with regex. How to find and save the search results as variable is also covered in this segment.
- ThePrimeagen live codes how to use macros to record a set of keystrokes and replay them for quick code repetition and editing large chunks of similar code. How to jump to the beginning of the line is also covered in this segment.
- ThePrimeagen discusses registers as a key value store and answers a student's question regarding what Lua and neovim are. Registers can be selected using double quotes and yanked to edit the original macro.
Text Manipulation
Section Duration: 53 minutes
- ThePrimeagen demonstrates some advanced motions including delete and enter insert mode and more complex horizontal, vertical, and core movements. These complex movements can be used to quickly and accurately move throughout the code.
- ThePrimeagen demonstrates more advanced motions including jumping by half a page, jumping to the next opening or closing curly brace, and deleting the content inside of curly brace pairs.
- ThePrimeagen answers a student's question regarding how to create a new line to paste on while in visual mode. More advanced movements including how to hold pasted code, utilize the system's clipboard, remapping in normal mode, and moving selected code snippets.
- ThePrimeagen live codes a scratch buffer vimL plugin. How to create a new buffer, set local options, and passing in the command to the systemlist. The setting nobuflisted will keep the files in memory, but hidden to increase the plugin speed.
- ThePrimeagen discusses what an ideal plugin should be and how they should have quick and intuitive commands to allow for faster user actions.
- ThePrimeagen discusses an ideal vim setup using harpoon and vim-fugitive as examples. An ideal vim experience should have everything one click away and flow naturally.
Wrapping Up
Section Duration: 6 minutes
- ThePrimeagen wraps up the course by answering student questions regarding different commands for plug, getting an editor going on a new system, personal workflow set up, and the benefits of vim over emacs.
Learn Straight from the Experts Who Shape the Modern Web
- In-depth Courses
- Industry Leading Experts
- Learning Paths
- Live Interactive Workshops