Mission 43 / 52• Text Objects - Paragraphs

Delete Around Paragraph

`dap` deletes the block of code *and* the blank line following it.

This prevents leaving trailing empty lines when deleting entire functions or sections.

Delete around paragraph

  • dapdelete paragraph and the accompanying blank line
1
// Block 1
2
const x = 1;
3
4
// Block 2
5
const y = 2;

Position on `Block 1` and type `dap`. Notice the blank line is removed alongside the code.

Now it's your turn!

  1. Navigate to each green target across the code snippet.
  2. Use the motions and techniques learned in this lesson to land accurately on each target.
  3. See how fast you can complete 10 targets.
0/10
1
// Block 1
2
const x = 1;
3
4
// Block 2
5
const y = 2;
NORMAL
00:00