Merge pull request #1488 from danielyxie/dev

revert dynamic ram miscalc
This commit is contained in:
hydroflame 2021-10-14 17:20:27 -04:00 committed by GitHub
commit f8a82c9a00
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 3 additions and 4 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

@ -28,8 +28,7 @@ export async function executeJSScript(scripts: Script[] = [], workerScript: Work
// but not really behaves like import. Particularly, it cannot
// load fully dynamic content. So we hide the import from webpack
// by placing it inside an eval call.
await script.updateRamUsage(scripts);
workerScript.ramUsage = script.ramUsage;
script.markUpdated();
uurls = _getScriptUrls(script, scripts, []);
script.url = uurls[uurls.length - 1].url;
script.module = new Promise((resolve) => resolve(eval("import(uurls[uurls.length - 1].url)")));