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
Make sure to pick the JSDoc option when prompted.
The Svelte 5 option is required for this one example, but trying to import Svelte 4 packages will result in the same issue.
Hmm... This one is hard to fix from our side. TypeScript provides the auto-import but they judge if the file is a js file with the file extension instead of ScriptKind API that we can override. Also, This specific case is a recent regression. We need to ask them if this can be changed back but still retain what the change is for. It might also be possible we have to rewrite the suggestion but it'll be hard.
Describe the bug
When importing a type using JSDoc, the autoimport solution uses TS syntax to import the type, instead of using JSDoc syntax.
Reproduction
Reproduction can be found here - https://github.com/razshare/svelte5-language-tools-jsdoc-autoimport-issue
Or simply create a new sveltekit project
Make sure to pick the JSDoc option when prompted.
The Svelte 5 option is required for this one example, but trying to import Svelte 4 packages will result in the same issue.
Then paste this into any component
Expected behaviour
When trying to import
Snippet
using the language tools (ctrl+space), the solution should import the type using JSDoc syntax.So the result should look like this
Or like this
Or even this, using ts >= 5.5
System Info
Which package is the issue about?
Svelte for VS Code extension
Additional Information, eg. Screenshots
No response
The text was updated successfully, but these errors were encountered: