[[language]]
name = "rust"
language-servers = ["rust-analyzer", "tailwindcss-ls"]

[language-server.rust-analyzer.config]
# procMacro = { ignored = { leptos_macro = ["server"] } }
cargo = { features = ["ssr", "hydrate"] }
check = { command = "check" }

rustfmt = { overrideCommand = ["leptosfmt", "--stdin", "--rustfmt"] }

# rustfmt = { overrideCommand = [
#   "sh",
#   "-c",
#   "set -euo pipefail; rustfmt --emit stdout --edition 2024 | leptosfmt --stdin",
# ] }

[language-server.tailwindcss-ls]
config = { userLanguages = { rust = "html", "*.rs" = "html" } }
