Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 3 additions & 12 deletions plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -133,18 +133,9 @@ class WasmPackPlugin {
return true;
}

info('ℹ️ Installing wasm-pack \n');

if (commandExistsSync("npm")) {
return runProcess("npm", ["install", "-g", "wasm-pack"], {});
} else if (commandExistsSync("yarn")) {
return runProcess("yarn", ["global", "add", "wasm-pack"], {});
} else {
error(
"⚠️ could not install wasm-pack, you must have yarn or npm installed"
);
}
return false
error('⚠️ Could not find wasm-pack\n Please install it via `yarn add -D wasm-pack`, `npm install --dev wasm-pack` or by following the instructions at: https://rustwasm.github.io/wasm-pack/installer/');

return false;
}

_compile(watching) {
Expand Down