Skip to content

Migrate one component at the time with the CLI #278

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
einarpersson opened this issue Nov 5, 2024 · 4 comments
Closed

Migrate one component at the time with the CLI #278

einarpersson opened this issue Nov 5, 2024 · 4 comments
Labels
enhancement New feature or request pkg:migrate svelte-migrate

Comments

@einarpersson
Copy link

Hi!

In the migration guide the CLI is recommended for migration of a whole app (or folders) - but if you want to migrate one component at the time you are out of luck if you are not using VSCode. This is something that should be available through the CLI, for all svelte users regardless of their editor preference in my opinion.

npx migrate svelte-5 <component.svelte>

@benmccann
Copy link
Member

As a workaround, you can migrate the whole project, commit the changes to the file you would like to migrate, then revert the rest.

@manuel3108
Copy link
Member

Makes sense. @benmccann would you mind moving this to the kit repo, as the migration script still lies there?

@Conduitry Conduitry transferred this issue from sveltejs/cli Nov 5, 2024
@benmccann benmccann transferred this issue from sveltejs/kit Nov 7, 2024
@manuel3108 manuel3108 added enhancement New feature or request pkg:migrate svelte-migrate labels Nov 29, 2024
@manuel3108 manuel3108 marked this as a duplicate of #451 Mar 8, 2025
@benmccann
Copy link
Member

#391 allows you to migrate sub-directories

And VS Code lets you migrate individual files

Do either of those address your need? I'm wondering if we should close this issue now

@einarpersson
Copy link
Author

migrating sub-directories is a step forward of course.

I'm however using neovim.

I dont need fancy prompts, just a flag :)

but to be honest, since this is just a one-time migration you can close it as far as i'm concerned.

I however do not like when "non-ui" functionality is only available through a vscode extension. the market / power concentration is high enough already in this world! I understand that there are a lot of vscode users but this just becomes a self reinforcing loop

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request pkg:migrate svelte-migrate
Projects
None yet
Development

No branches or pull requests

3 participants