Skip to content

Commit f6ad4a1

Browse files
liujupingLeoYuan
authored andcommitted
feat: assetLoader loda scripts with async=false
1 parent f0d8b85 commit f6ad4a1

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

packages/utils/src/script.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,9 +29,11 @@ export function load(url: string) {
2929
// node = null;
3030
}
3131

32-
// node.async = true;
3332
node.src = url;
3433

34+
// `async=false` is required to make sure all js resources execute sequentially.
35+
node.async = false;
36+
3537
document.head.appendChild(node);
3638

3739
return i.promise();

0 commit comments

Comments
 (0)