tensor-programming / wasm_snake_example

23 stars 5 forks source link

package.json? #1

Open Mobilpadde opened 6 years ago

Mobilpadde commented 6 years ago

I think the package.json is missing 😇😅

S0AndS0 commented 4 years ago

I don't think a package.json is required, because yarn and Node packages aren't required. Attached are the steps I utilized for set-up and testing.


Install dependencies...

rustup target add wasm32-unknown-unknown
cargo install cargo-web

Make a Rust project and cd into it's root...

mkdir -v git/local/rust-wasm
cd git/local/rust-wasm

cargo init wasm-snake
cd wasm-snake

Follow along with videos...

Then compile and start development server...

cargo web start --target=wasm32-unknown-unknown

Open a browser pointing at localhost...

firefox http://localhost:8000

And enjoy :-D

Attribution