elm-language-server
elm-language-server copied to clipboard
Feature: Move function/type
Expected Behavior
When activating quickfix through the vscode command "editor.action.quickFix" while the cursor is on a function declaration or on a type declaration; I want the option to move that function/type to another file, automatically updating the import statements on all files where the function/type is used.
Current Behavior
No move action available on "quickFix"
Context
When refractoring big elm apps, sometimes I need to move functions between files, to keep a clear separation of concerns.
Right now, this is a lot of manual work, where I:
- cut the functiuon/type from module 1
- paste the function/type in module 2
- expose the function/type in module 2
- unexpose the function/type in module 1
- compile
- go through all import-errors one by one, adjusting the imports to point to module 2 instead of module 1
Functions can be moved since march, types still need to be implemented