Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Types not updated after editing #91

Closed
sebkolind opened this issue Nov 19, 2020 · 9 comments · Fixed by #110
Closed

Types not updated after editing #91

sebkolind opened this issue Nov 19, 2020 · 9 comments · Fixed by #110

Comments

@sebkolind
Copy link

sebkolind commented Nov 19, 2020

I installed the latest lsp-vue and lsp packages and typescript (with the lsp-typescript package).

When I have a .vue file open, and that file is using an external class, and I go to the external class and edit a method, for example the required paramters, and go back to my .vue file it's not updated with the new parameters for that method. I have to either:

  1. Restart Sublime
  2. Close the .vue file and Restart LSP Servers and then open the file again.

It is working just fine in regular .ts files, but for .vue files it is like the LSP is not updating.

@rchl
Copy link
Member

rchl commented Nov 19, 2020

That's due to missing support for workspace/didChangeWatchedFiles: sublimelsp/LSP#892

For now, the workaround is to restart the servers using command pallette or restart ST.

@rchl
Copy link
Member

rchl commented Nov 19, 2020

BTW. It works for .ts files because the typescript server is running a file watcher internally, something that most servers moved away from already as it doesn't scale with multiple servers. But that server is a bit older so it's still doing that itself.

@sebkolind
Copy link
Author

@rchl I see - that is a shame. I could not find any information regarding when that feature will be supported. Do you know anything? I am running the ST4 dev build, and it doesn't work either for that version.

@rchl
Copy link
Member

rchl commented Nov 20, 2020

It depends on this feature request - sublimehq/sublime_text#2669

There is no timeline for when this (or any other) feature will be implemented but ST devs were pretty good at accommodating LSP latety so if not for the next major release then hopefully after that.

(Feel free to "thumbs up" that feature request to show that there is interest)

@rchl rchl reopened this Nov 20, 2020
@rchl
Copy link
Member

rchl commented Nov 20, 2020

We can keep this open since even once the feature is implemented, this plugin will need to be changed to register the watchers.

@kodi
Copy link

kodi commented Sep 22, 2021

Any news on this?

Really enjoying speed of Sublime4 + LSP + vue :)
This is one of just 2-3 small issues that is just bugging me in my daily work.

@rchl
Copy link
Member

rchl commented Sep 22, 2021

I will soon release an "addon" package that will add this functionality through third-party file-watcher - sublimelsp/LSP-file-watcher-chokidar#1

Probably in few days.

@rchl
Copy link
Member

rchl commented Oct 4, 2021

Implemented through https://packagecontrol.io/packages/LSP-file-watcher-chokidar

That package needs to be installed in addition to LSP and LSP-vue.

@predragnikolic
Copy link
Member

Can this be now closed?

@rchl rchl closed this as completed Oct 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants