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

Consider some strategy for handling "preview" files in TSServer that don't need full project information #35114

Closed
DanielRosenwasser opened this issue Nov 14, 2019 · 3 comments
Labels
Declined The issue was declined as something which matches the TypeScript vision Domain: Performance Reports of unusually slow behavior Rescheduled This issue was previously scheduled to an earlier milestone Suggestion An idea for TypeScript

Comments

@DanielRosenwasser
Copy link
Member

Today, navigating to a file in another project for a preview will load an entire project. Bad! Much of the time, a user might only care about certain operations (e.g. outlining, brace matching, whatever).

There's basically two high-level ideas here:

  • A new file open request, or meta information, that tells the semantic server that it shouldn't try to fully load the full program until a semantic operation occurs
  • Editors will "know better" and only dispatch to a separate syntactic server. This requires no work from our end, but we should acknowledge that that's the path forward. (@mjbvz)
@DanielRosenwasser DanielRosenwasser added the Domain: Performance Reports of unusually slow behavior label Nov 15, 2019
@DanielRosenwasser DanielRosenwasser changed the title Consider some strategy for handling "temporary" files in TSServer that don't need full project information Consider some strategy for handling "preview" files in TSServer that don't need full project information Nov 15, 2019
@DanielRosenwasser DanielRosenwasser added this to the TypeScript 3.9.0 milestone Mar 3, 2020
@DanielRosenwasser DanielRosenwasser added In Discussion Not yet reached consensus Suggestion An idea for TypeScript labels Mar 3, 2020
@DanielRosenwasser
Copy link
Member Author

Let's talk about this at tomorrow's editor sync.

@DanielRosenwasser
Copy link
Member Author

One question that came out was whether we could have a "naive mode" for preview tabs. The idea is that go-to-definition works on many constructs like exports and can jump across files and the like, but it might not work all the time, and things like quick info might not work at all. We might be able to get away with doing a lot of this from the syntax server.

Ultimately, this just needs some sort of user story spec'd out.

@RyanCavanaugh RyanCavanaugh added the Rescheduled This issue was previously scheduled to an earlier milestone label May 20, 2020
@RyanCavanaugh
Copy link
Member

Closing in lieu of #39035

@DanielRosenwasser DanielRosenwasser removed this from the TypeScript 4.0.1 milestone Jul 15, 2020
@DanielRosenwasser DanielRosenwasser added Declined The issue was declined as something which matches the TypeScript vision and removed In Discussion Not yet reached consensus labels Jul 15, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Declined The issue was declined as something which matches the TypeScript vision Domain: Performance Reports of unusually slow behavior Rescheduled This issue was previously scheduled to an earlier milestone Suggestion An idea for TypeScript
Projects
None yet
Development

No branches or pull requests

2 participants