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

Method prependLeft

benchmark/data-min.js:456–461  ·  view source on GitHub ↗
(t, e)

Source from the content-addressed store, hash-verified

454 return ((this.intro = t + this.intro), this);
455 }
456 prependLeft(t, e) {
457 if (typeof e != 'string') throw new TypeError('inserted content must be a string');
458 this._split(t);
459 const n = this.byEnd[t];
460 return (n ? n.prependLeft(e) : (this.intro = e + this.intro), this);
461 }
462 prependRight(t, e) {
463 if (typeof e != 'string') throw new TypeError('inserted content must be a string');
464 this._split(t);

Callers

nothing calls this directly

Calls 2

_splitMethod · 0.95
prependLeftMethod · 0.45

Tested by

no test coverage detected