You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I had been reading the book while learning leptos (using the 0.8 alpha branch if that matters). Overall, great experience, thanks! I noticed a few inconsistencies - things working differently nowadays, some broken links etc.
I don't know what, when (or even if?) something changed, but I removed server from the proc macro ignore list and the editor auto-complete works fine for me? (Visual Studio Code 1.98, rust-analyzer 0.3.2337, leptos-related crates @ leptos-rs/leptos@d0bf843)
Seems like the macro is expanded properly and gives great IDE support for ServerActions created with it
Maybe we should add another note saying that #[server] macros should work with rust-analyzer and make the proc macro ignore list completely optional in the book?
The text was updated successfully, but these errors were encountered:
PR welcome to add such a note, and/or to fix any of the inconsistencies or broken links you noticed. We've tried to make support for completion within the macros better over time, so I'm not surprised if it's gotten better.
Ah sorry, I've just noticed that rust-analyzer can't figure out the original function if #[server] is expanded. While (obviously) it can't figure out the generated ServerAction struct if macro expansion is disabled. So I guess the point from the book still stands, I just forgot to look back at the function :/
I'll take a look at the other stuff and see if I can produce a good PR though!
Hi, I had been reading the book while learning leptos (using the 0.8 alpha branch if that matters). Overall, great experience, thanks! I noticed a few inconsistencies - things working differently nowadays, some broken links etc.
https://github.com/leptos-rs/book/blob/5b2c1abc65452e71539f612428d34d72cfa358b5/src/getting_started/leptos_dx.md#2-editor-autocompletion-inside-component-and-server
I don't know what, when (or even if?) something changed, but I removed
server
from the proc macro ignore list and the editor auto-complete works fine for me? (Visual Studio Code 1.98, rust-analyzer 0.3.2337, leptos-related crates @ leptos-rs/leptos@d0bf843)Seems like the macro is expanded properly and gives great IDE support for ServerActions created with it
Maybe we should add another note saying that
#[server]
macros should work with rust-analyzer and make the proc macro ignore list completely optional in the book?The text was updated successfully, but these errors were encountered: