Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign upGitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.
Sign up
This would fix (or make unnecessary) brendanzab/gl-rs#528, which was an attempt to fix
webgl_stdwebcompiling underwasm-pack/wasm-bindgen. It was giving me these kind of errors:I was able to patch it by just adding
wasm-bindgenas a dep towebgl_stdweb, but I realized I was also able to fix it directly in stdweb by importingwasm_bindgeninside thejs!()/derive(ReferenceType)macros. I think it was failing becausewasm-bindgen's macros expect to be able to accesswasm_bindgen, but because crates invoking thestdwebmacros that invoke thewasm-bindgenmacros don't necessarily havewasm_bindgenin scope, it might fail to compile.