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

Method clone

benchmark/data.js:880–893  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

878 return this;
879 }
880 clone() {
881 const bundle = new Bundle({
882 intro: this.intro,
883 separator: this.separator,
884 });
885 this.sources.forEach((source) => {
886 bundle.addSource({
887 filename: source.filename,
888 content: source.content.clone(),
889 separator: source.separator,
890 });
891 });
892 return bundle;
893 }
894 generateDecodedMap(options = {}) {
895 const names = [];
896 this.sources.forEach((source) => {

Callers

nothing calls this directly

Calls 2

addSourceMethod · 0.95
cloneMethod · 0.45

Tested by

no test coverage detected