Skip to content

Poor UX for file refactorings #75877

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

Closed
fgarcia opened this issue Jun 21, 2019 · 5 comments
Closed

Poor UX for file refactorings #75877

fgarcia opened this issue Jun 21, 2019 · 5 comments
Assignees
Labels
javascript JavaScript support issues perf typescript Typescript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code)

Comments

@fgarcia
Copy link

fgarcia commented Jun 21, 2019

Moving and renaming files is one of my basic refactorings. I am so glad VSCode is capable of updating each import in my source code, however this task has one big pain points

File refactorings only work with a drag-drop action on the sidebar. That tends to be very painful on projects with a big tree layout or with limited screen space (ie: a laptop).

PROPOSAL: Add a context menu and/or a command reachable from "F1" where I can request to move file (makes the refactoring discoverable) and give the new path. It might be just typing a path, but also might be triggering a file explorer dialog

@sandy081
Copy link
Member

@fgarcia What is the programming language of the files you are trying to refactor by moving?

@sandy081 sandy081 added the info-needed Issue requires more information from poster label Jun 21, 2019
@fgarcia
Copy link
Author

fgarcia commented Jun 21, 2019

@sandy081 Typescript

@mjbvz mjbvz self-assigned this Jun 21, 2019
@mjbvz mjbvz removed the info-needed Issue requires more information from poster label Jun 21, 2019
@mjbvz
Copy link
Collaborator

mjbvz commented Jun 21, 2019

This slowness is microsoft/TypeScript#30535. We do show a message in the status bar while we are checking if a rename can be performed:

Screen Shot 2019-06-21 at 2 13 58 PM

Unfortunately, even we a different UI, the rename operation would still be slow due to microsoft/TypeScript#30535. We'll keep investigating the root cause of the slowness upstream.

@mjbvz mjbvz closed this as completed Jun 21, 2019
@mjbvz mjbvz added javascript JavaScript support issues perf typescript Typescript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code) labels Jun 21, 2019
@fgarcia
Copy link
Author

fgarcia commented Jun 22, 2019

My main concern was never the slowness. It was about how complicated it was to perform and discover the action.

It is not exposed as a command/action or a context menu. The only way to perform the action is through drag and drop. Which is a big problem when working on a laptop (small screen) or big code trees (like a monorepo)

@mjbvz Please, if you can, remove the "perf" tag. Also my status bar is not showing that notification, I might write another concern. Something like being able to type a path would ease so much using this refactoring

@fgarcia
Copy link
Author

fgarcia commented Jun 22, 2019

@sandy081 I've just re-edited the issue to focus on my concern. I hope it is clear now it was not really a typescript problem, but an issue with the editor interface

@vscodebot vscodebot bot locked and limited conversation to collaborators Aug 5, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
javascript JavaScript support issues perf typescript Typescript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code)
Projects
None yet
Development

No branches or pull requests

3 participants