What can I do with visual mode?
We’ve now learned how to use the different variants of visual mode to select a region of text. But what can we actually do with it? So far we’ve only deleted regions of text — but there’s more we can do.
You can use the following key maps in visual mode:
- x or d to delete
- c to change — i.e. deleting your entire selection, then dropping you into insert mode
- y to “yank” — this is similar to copying to the clipboard, and we’ll learn more about this in the next lesson
- > to indent forward
- < to indent backwards
Work through the checklist below. Don’t feel like you need to try yanking for now, though; we’re going to learn about that soon.