Skip to main content
Deno 2 is finally here 🎉️
Learn more
Module

x/deno2node/src/deps.deno.ts>TextInsertableNode

Compile your Deno project to run on Node.js.
Go to Latest
interface TextInsertableNode
import { type TextInsertableNode } from "https://deno.land/x/deno2node@v1.10.0/src/deps.deno.ts";

Methods

insertText(pos: number, textOrWriterFunction: string | WriterFunction): this

Inserts text within the body of the node.

WARNING: This will forget any previously navigated descendant nodes.

replaceText(range: [number, number], textOrWriterFunction: string | WriterFunction): this

Replaces text within the body of the node.

WARNING: This will forget any previously navigated descendant nodes.

removeText(): this

Removes all the text within the node

removeText(pos: number, end: number): this

Removes text within the body of the node.

WARNING: This will forget any previously navigated descendant nodes.

function TextInsertableNode
import { TextInsertableNode } from "https://deno.land/x/deno2node@v1.10.0/src/deps.deno.ts";

Type Parameters

T extends Constructor<TextInsertableNodeExtensionType>