Update build.sh

Does in fact work with `--mode=production`
This commit is contained in:
bspeice 2018-09-12 22:40:19 -04:00 committed by GitHub
parent d6c662ac80
commit 63ac0db821
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -23,5 +23,5 @@ cp "$DIR/WasmMainTemplatePlugin.patched.js" "$DIR/node_modules/webpack/lib/wasm/
cargo +nightly build --target=wasm32-unknown-unknown && \
wasm-bindgen "$WASM_DIR/debug/$WASM_NAME.wasm" --out-dir "$APP_DIR" --no-typescript && \
# Still doesn't work with mode=production, not sure why
# --mode=production requires https://github.com/webpack/webpack/pull/7732
"$DIR/node_modules/webpack-cli/bin/cli.js" --mode=production "$APP_DIR/app_loader.js" -o "$APP_DIR/bundle.js"