We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0cc21e8 commit 48af744Copy full SHA for 48af744
wasm/index.mjs
@@ -4,6 +4,8 @@ import { await_promise_sync, createBundleAsync } from './async.mjs';
4
let wasm, bundleAsyncInternal;
5
6
export default async function init(input) {
7
+ if (wasm) return;
8
+
9
input = input ?? new URL('lightningcss_node.wasm', import.meta.url);
10
if (typeof input === 'string' || (typeof Request === 'function' && input instanceof Request) || (typeof URL === 'function' && input instanceof URL)) {
11
input = fetchOrReadFromFs(input);
0 commit comments