Open lucitang opened 1 year ago
Yep this happened to me too, I fixed it by setting the NODE_OPTIONS
environmental variable to --openssl-legacy-provider
I don't have high hopes that this will be added in the book though, since it hasn't been updated since January 2021
I mitigated this with the same solution (NODE_OPTIONS
to --openssl-legacy-provider
). You can modify the generated package.json, you don't have to modify your environment.
www
directory: npm install --save-dev cross-env
start
script to: cross-env NODE_OPTIONS='--openssl-legacy-provider' webpack-dev-server
npm run start
After I ran npm install
I ran npm update
and it worked fine.
I guess it has something to do with outdated dependencies that npm init wasm-app
provides.
There is a solution here: https://github.com/rustwasm/rust-webpack-template/issues/184
@paphopsaw This also worked for me, and is more coherent!
when i run npm run start from the www folder in the project i get an error:
rustc version: 1.71.0 npm version: 9.8.1