ERASE_LINE_AFTER_CURSOR

import { ERASE_LINE_AFTER_CURSOR } from "jsr:@ende/cli/unstable-ansi";

variable ยท experimental

const ERASE_LINE_AFTER_CURSOR: "\u001b[0K"

Erases line content to the right of cursor position.

Returns

The ANSI escape code for erasing the line content to the right of the cursor.

Example: Usage

import { delay } from "@ende/async/delay";
import * as Ansi from "@ende/cli/unstable-ansi";

console.log("Hello World!");
await delay(1000);
console.log(
  Ansi.moveCursorUp() +
    Ansi.setCursorColumn(7) +
    Ansi.ERASE_LINE_AFTER_CURSOR,
);

Source