create-wasm-app icon indicating copy to clipboard operation
create-wasm-app copied to clipboard

This module doesn't work anymore

Open Kreijstal opened this issue 3 years ago • 9 comments

I mean it dependencies have updated A lot and there are many breaking changes

webpack              ^4.29.3  →  ^5.74.0
webpack-cli           ^3.1.0  →  ^4.10.0
webpack-dev-server    ^3.1.5  →  ^4.11.1

I guess you shouldn't have used webpack then 😝 simply use --target web I suppose.

Kreijstal avatar Oct 07 '22 20:10 Kreijstal

You can still run it using

node v12.22.12
npm 6.14.16

I used nvm install 12 and nvm use 12 to quickly install node 12.

derdrdirk avatar Feb 18 '23 20:02 derdrdirk

Yes this template needs to be either updated or the tutorial and web book on rust+wasm (game of life) should not recommend this template. I have had to switch to using --target web instead

jack-mil avatar Apr 23 '23 17:04 jack-mil

Has anyone found any good alternatives?

adazoulay avatar Jun 01 '23 05:06 adazoulay

Please look at the changes in this PR-208 which helps resolve this issue.

olaitanade avatar Jan 30 '24 11:01 olaitanade

With latest Node version: v20.11.0 and following dependencies it runs clean. package.json:

"dependencies": { "wasm-game-of-life": "file:../pkg" }, "devDependencies": { "copy-webpack-plugin": "^12.0.2", "webpack": "^5.90.1", "webpack-cli": "^5.1.4", "webpack-dev-server": "^4.15.1" }

And webpack.config.js should be replaced with:

const CopyPlugin = require("copy-webpack-plugin"); const path = require('path');

module.exports = { entry: "./bootstrap.js", output: { path: path.resolve(__dirname, "dist"), filename: "bootstrap.js", }, mode: "development", experiments: { syncWebAssembly: true // Enable WebAssembly experiments }, plugins: [ new CopyPlugin({ patterns: [ { from: "index.html", to: "index.html" } ] }) ], };

ratulb avatar Feb 11 '24 01:02 ratulb

what @ratulb suggested works. is this project not supported anymore?

anranlee99 avatar Mar 22 '24 07:03 anranlee99

Seems this book is unmantained

Kreijstal avatar Mar 22 '24 07:03 Kreijstal