When I open the DOM web-sys example with VS Code (using the latest rust-analyzer), I don't get any autocompletion after typing document..
Is this to be expected because of the #[wasm_bindgen] attribute macro?
I tried enabling rust-analyzer.experimental.procAttrMacros but that didn't help.
I don't think it's this specific bug, since that bug is about function-like instead of attribute-like macros and also the behavior with wasm-bindgen is worse: I don't get autocompletion for getElementId even after typing document.get.
This isn't about attribute macros in general, autocompletion works fine in #[tokio::main] attributed functions for example, so there must be something that the wasm-bindgen macro is doing in specific that breaks rust-analyzer.
I don't know if this is something rust-analyzer can improve since I think that there are some macros that rust-analyzer won't ever support since they are way too complicated. If that's the case maybe wasm-bindgen could be adapted with such limitations in mind.
That bug applies to macros in general, and is particularly hard to fix for procedural macros (to the point that it either requires some hacks that let macro authors opt in to a workaround, or support from syn that is equivalent to a rewrite and large breaking change).
Sorry, I should have been more specific. Hover doesn't work in the following inner! macro. (Note that the macro has been simplified, the real macro actually used the $d argument).