[wasm] build: allow dev build
This commit is contained in:
parent
7ac92f9341
commit
5de74ba6c3
@ -62,7 +62,8 @@ async function main() {
|
|||||||
const wasmDistDir = path.resolve(__dirname, 'dist');
|
const wasmDistDir = path.resolve(__dirname, 'dist');
|
||||||
await rm(wasmOutDir, { recursive: true, force: true });
|
await rm(wasmOutDir, { recursive: true, force: true });
|
||||||
const wasmRelOutDir = path.relative(wasmSourceDir, wasmOutDir);
|
const wasmRelOutDir = path.relative(wasmSourceDir, wasmOutDir);
|
||||||
await run(['wasm-pack', 'build', '--target', 'web', '--out-dir', wasmRelOutDir], {
|
const profileFlag = process.env.BUILD_RELEASE ? '--release' : '--dev';
|
||||||
|
await run(['wasm-pack', 'build', profileFlag, '--target', 'web', '--out-dir', wasmRelOutDir], {
|
||||||
cwd: path.resolve(__dirname, '..', 'um_wasm'),
|
cwd: path.resolve(__dirname, '..', 'um_wasm'),
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user