MCPcopy Create free account
hub / github.com/facebook/memlab / rewriteScript

Method rewriteScript

packages/e2e/src/ScriptManager.ts:99–111  ·  view source on GitHub ↗
(
    code: string,
    options: RewriteScriptOption = {},
  )

Source from the content-addressed store, hash-verified

97 }
98
99 public async rewriteScript(
100 code: string,
101 options: RewriteScriptOption = {},
102 ): Promise<string> {
103 if (!config.instrumentJS) {
104 return code;
105 }
106 const newCode = await this.scriptRewriteManager.rewriteScript(
107 code,
108 options,
109 );
110 return newCode;
111 }
112
113 public resourceTypeToSuffix(resourceType: string): string {
114 switch (resourceType) {

Callers 1

interceptScriptMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected