-
Notifications
You must be signed in to change notification settings - Fork 214
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
Dropdown for Move Generator after selecting Move in Context menu #1273
Comments
@MaxKless this may be a good one to bump up in priority, although I'm a bit biased. What do you think? |
Yeah it sounds useful. I'm not sure what a "dropdown" means for context menus, though. I'm just wondering if there isn't a smart way to figure out which generator is the right one based on the selected project... |
There's not a good way to tell which generator is correct, because idealistically it would be provided by the plugin which scaffolded the project. But there's no way to know what that generator was after generation. For the common ones, you could theoretically check between things like if it uses @nrwl/angular for build since the only options we provide are @nrwl/angular or @nrwl/workspace, but when you consider community plugins as a need you wouldn't be able to reliably detect it imho. Consider a plugin like @nx-community/vue (made up) that has its own move generator but uses our vite or webpack plugin for its targets. No real way to trace it back.
I think the context menu would just open a prompt which contains an autocomplete style dropdown, similar to how the |
Makes sense on the first part. Concerning the prompt, I don't really like the idea of having a prompt because it forces you to switch between the context menu and the top of the screen even though it's such a tightly coupled relationship between the menus. I'll see how it feels and whether dynamic context menus are even a thing :) |
Turns out dynamic submenus don't exist :) |
Sure, I think a quickpick will work for the time being and if the vscode issue ever makes progress it should be an easy swap. |
Hey @AgentEnder I made a PR addressing this: #1534 Running remove/move from the context menu now lets you select the generator. I'd be glad if you could try it out or provide some feedback from real-life @nx-dotnet workspaces. Maybe there's some details I haven't taken into consideration. |
merged :) |
Awesome, once its released I'll do a quick double check on if it picks up the move generator for us. |
Description
Capturing @AgentEnder's comment to #1256:
A dropdown seems like the correct path forward after talking it over with @Cammisuli. We'll look to add this in the future for support for 3rd party plugins and orgs with their own move implementations.
The text was updated successfully, but these errors were encountered: