StyLua
StyLua copied to clipboard
Update wasm-bindgen and wasm-pack to resolve ReferenceError
Hello! I'm trying to use the npm package via vite-plugin-wasm, but I'm running into the following error:
Uncaught ReferenceError: Cannot access 'memory' before initialization
at stylua_lib_bg.js?v=4e2ee103:671:42
(anonymous) @ stylua_lib_bg.js?v=4e2ee103:671
I believe this error is the same as https://github.com/Menci/vite-plugin-wasm/issues/8#issuecomment-1193187290. It sounds like that was resolved by https://github.com/rustwasm/wasm-bindgen/pull/2965, but that fix is only present in wasm-bindgen 0.2.82 and onwards (but this project is using 0.2.81). I was wondering if you'd have any problem with updating things to incorporate the fix.
Nope no problems, we can update this. Also happy to accept a PR to do so