zed
zed copied to clipboard
Go to definition not working again in .svelte files
Check for existing issues
- [X] Completed
Describe the bug / provide steps to reproduce it
Go to definition not working in .svelte files
Environment
Zed: v0.141.3 (Zed) OS: macOS 14.4.1 Memory: 8 GiB Architecture: aarch64
If applicable, add mockups / screenshots to help explain present your vision of the feature
No response
If applicable, attach your ~/Library/Logs/Zed/Zed.log file to this issue.
Zed.log
[Zed.log](https://github.com/user-attachments/files/16081147/Zed.log)
It seems that the Snippet extension was causing this, so it is related to https://github.com/zed-industries/zed/issues/13282 Uninstalling the Snippet extension fixed the issue. That said both features were working well together until yesterday, and I can't say which update of what broke that harmony...
Edit : without the snippet extension go to definition now worked, but autocompletion and auto-import doesn't at all in script tag.
Go to Definition and Hover Documentation is not working for me in .svelte files either. I do not have the Snippet ext. only the Svelte one.
Edit : without the snippet extension go to definition now worked, but autocompletion and auto-import doesn't at all in script tag.
Can confirm the issue went away after uninstalling snippet extension ( Zed 0.146.5, Linux ) 🥲
Go to Definition and Hover Documentation is not working for me in .svelte files either. I do not have the Snippet ext. only the Svelte one.
+1 (Zed 0.148.1, macOS x86)
+1, not working for me either. No snippet extension
Update : Go to definition works correctly after Zed 0.147.2 update, but fail after 0.148
Also getting this issue, using Svelte 5 and on MacOS Zed 0.149.3
I’m experiencing the same issue with Svelte 4 on MacOS Sonoma, running Zed version 0.149.3
Go to definition has completely stopped working for me in .svelte files in this most release of Zed 0.149.3.
This is what helped me bring it back - I added svelte-language-server to languages section in settings and it worked.
"languages": {
"Svelte": {
"formatter": "language_server",
"language_servers": ["svelte-language-server"],
"prettier": {
"allowed": true
}
},
}
Guess the same issue as #16619?
I have something that looks like a fix, waiting for the review/confirmation: https://github.com/zed-industries/zed/pull/16654
Meanwhile, using
"languages": {
"Svelte": {
// this is a new line
"language_servers": ["svelte-language-server", "..."],
"prettier": {
"allowed": true,
"plugins": ["prettier-plugin-svelte"]
}
},
}
could help as a workaround.
For those just using typescript and eslint, here's a config that worked for me with the new update
"languages": {
"Svelte": {
"prettier": {
"allowed": true
},
"format_on_save": "prettier",
"code_actions_on_format": {
"source.fixAll.eslint": true
}
}
}