Skip to content
This repository has been archived by the owner on Apr 1, 2020. It is now read-only.

Refactoring Support #474

Open
bryphe opened this issue Jun 4, 2017 · 0 comments
Open

Refactoring Support #474

bryphe opened this issue Jun 4, 2017 · 0 comments
Milestone

Comments

@bryphe
Copy link
Member

bryphe commented Jun 4, 2017

Initial refactoring support has landed in TypeScript:
microsoft/TypeScript#15569

This would be a great feature for Oni - this is sort of a next-tier IDE feature that has the potential for huge productivity boosts.

There are a couple of issues that need to be considered:

  • This isn't supported in a first class way by the language server protocol. There are still open issues in terms of how it may be handled: An operation for refactorings microsoft/language-server-protocol#61 The approach that I believe makes sense would be to create an Oni API that exposes some of this functionality - like we already do for completion, and then if the LSP supports it, the LanguageClient.ts could call back into that API. This would allow other plugins / languages to do support refactoring strategies as well - it's just a bummer that it doesn't come through the LSP at the moment. There will be similiar pieces of functionality like this down the road - live reload, debugging, where standards are still in flux.
  • Plugin API design for this - need to investigate and see the functionality the tsserver provides.
  • Applying the TextEdit - I'm hoping we can reuse the strategy for modifying code that things like formatting provides - the TextEdit object seems applicable for this.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant