In Vim, you can delete entire lines or parts of lines using the d command.
const name = "Vim";let count = 42; let score = 100;const PI = 3.14; const items = [1, 2, 3];const MAX = 1000;
The D command is a quick way to delete from the cursor to the end of the line. It's equivalent to d$.