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

TypeScript Linter: Update File with Each Request #336

Closed
curran opened this issue Nov 10, 2023 · 1 comment · Fixed by #342
Closed

TypeScript Linter: Update File with Each Request #336

curran opened this issue Nov 10, 2023 · 1 comment · Fixed by #342
Assignees

Comments

@curran
Copy link
Contributor

curran commented Nov 10, 2023

https://github.com/vizhub-core/vzcode/pull/335/files/e7cf729e914f3fc77216f0f906b268692d2dea7b#diff-e2b50b056500704b20f1ea54e0b788eaed9c52d4c207d093efce243e9cce694cR197

In src/client/useTypeScript/worker.ts line 197:

It's possible that a linting request is made before a completion request, and also before the debounced ShareDB updating logic has a chance to set the correct file content.

image

In fact while testing I received this error, indicating that the TS FS did not have the latest. We may want to update it here as well, on each request, just like we do for the completions.

@EvWhymark
Copy link
Collaborator

When running the file updates alongside the linter request it really messes up our typescript environment. Our autocompletions still work however the linter does not properly update as we type text. My current thoughts are that we cant update file content as we are running our linter request. We need to do it some other way. Maybe as a independent request to the web worker?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants