on master help sign in
Update build script for no-modules examples
9fe3829Nick Fitzgerald
build.sh+1−17
@@ -3,8 +3,6 @@
3cd $(dirname $0)
3cd $(dirname $0)
4set -eux
4set -eux
5
5
6−INSTALL=${INSTALL:-""}
7−
8function with_dir {
6function with_dir {
9 pushd $1
7 pushd $1
10 shift
8 shift
@@ -15,20 +13,6 @@ function with_dir {
15cargo fmt --all
13cargo fmt --all
16cargo check --all --target wasm32-unknown-unknown
14cargo check --all --target wasm32-unknown-unknown
17
15
18−if test "$INSTALL" != ""; then
19− with_dir ./js npm link
20−fi
21−
22for x in ./examples/*; do
16for x in ./examples/*; do
23− wasm-pack build "$x/crate"
17+ wasm-pack build --target no-modules "$x"
24−
25− if test "$INSTALL" != ""; then
26− with_dir "$x/crate/pkg" npm link
27− with_dir "$x/crate/pkg" npm link dodrio
28− with_dir "$x/js" npm audit fix
29− with_dir "$x/js" npm install
30− with_dir "$x/js" npm link dodrio
31− fi
32−
33− with_dir "$x/js/" npm run build
34done
18done