We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Run the following code instead:
cargo generate --git https://github.com/rustwasm/wasm-pack-template # Type wasm-game-of-life
and then
cd wasm-game-of-life wasm-pack build npm init wasm-app www # Fix dependencies. We will first install sd to make replacing text easier and cross-platform and rusty. cargo install sd sd ' "devDependencies": \{ "hello-wasm-pack": "\^0.1.0", "webpack": "\^4.29.3", "webpack-cli": "\^3.1.0", "webpack-dev-server": "\^3.1.5", "copy-webpack-plugin": "\^5.0.0" \}' ' "dependencies": { "wasm-game-of-life": "file:../pkg" }, "devDependencies": { "copy-webpack-plugin": "^11.0.0", "hello-wasm-pack": "^0.1.0", "webpack": "^5.90.0", "webpack-cli": "^5.1.4", "webpack-dev-server": "^4.15.1" }' www/package.json cd www rm package-lock.json npm install # Fix webpack config sd -F "new CopyWebpackPlugin(['index.html'])" 'new CopyWebpackPlugin({ patterns: ["index.html"] })' webpack.config.js sd '^\}' ' experiments: { asyncWebAssembly: true },\n}' webpack.config.js npm run start
This should work in bash. In zsh you can just run it all at once for some reason
bash
zsh
The text was updated successfully, but these errors were encountered:
Thanks for this, was really helpful.
I was still having issues with this but I changed the devDependencies in package.json to this:
devDependencies
package.json
"devDependencies": { "copy-webpack-plugin": "^11.0.0", "hello-wasm-pack": "^0.1.0", "webpack": "^5.88.1", "webpack-cli": "^5.1.4", "webpack-dev-server": "^4.15.1" }
and that fixed it.
Sorry, something went wrong.
@magnus-ISU, did you PR the wasm-pack-template?
wasm-pack-template
No branches or pull requests
Run the following code instead:
and then
This should work in
bash
. Inzsh
you can just run it all at once for some reasonThe text was updated successfully, but these errors were encountered: