MCPcopy Create free account
hub / github.com/Rich-Harris/magic-string / insertRight

Method insertRight

src/MagicString.ts:465–474  ·  view source on GitHub ↗

@internal

(index: number, content: string)

Source from the content-addressed store, hash-verified

463
464 /** @internal */
465 insertRight(index: number, content: string): this {
466 if (!warned.insertRight) {
467 console.warn(
468 'magicString.insertRight(...) is deprecated. Use magicString.prependRight(...) instead',
469 )
470 warned.insertRight = true
471 }
472
473 return this.prependRight(index, content)
474 }
475
476 /**
477 * Moves the characters from `start` and `end` to `index`.

Callers

nothing calls this directly

Calls 1

prependRightMethod · 0.95

Tested by

no test coverage detected