Skip to content
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

v5 Migration #1437

Closed
MentalGear opened this issue Nov 3, 2024 · 10 comments
Closed

v5 Migration #1437

MentalGear opened this issue Nov 3, 2024 · 10 comments
Labels
status: help wanted This issue is tentatively accepted pending a volunteer committed to its implementation type: documentation A change or addition to the documentation

Comments

@MentalGear
Copy link
Contributor

Change Type

Addition

Proposed Changes

Thx for proving v.5 svelte support !

Please add a migration page so we know what needs to be done to upgrade.

@MentalGear MentalGear added the type: documentation A change or addition to the documentation label Nov 3, 2024
@skylerknight
Copy link

I had to manually install bits-ui@next with the latest version for anyone else having issues with the installation process

@huntabyte
Copy link
Owner

There will be a migration guide for Bits UI, but it's unlikely I'll have time to do a full-fledged one for both; I'm just one person 😃 however, if someone in the community would like to contribute one, that would be amazing!

@huntabyte huntabyte added the status: help wanted This issue is tentatively accepted pending a volunteer committed to its implementation label Nov 3, 2024
@MentalGear
Copy link
Contributor Author

Very understandable, thank you again for your amazing work!
Let's collect migration feedback in this issue and then fill a docs page with it as general tips.

@ieedan
Copy link
Contributor

ieedan commented Nov 4, 2024

So far here's what I have identified:

  1. migrate components with shadcn-svelte@next add (or update once it's fixed) also be aware of components that have custom code as you will need to reimplement any of that yourself
  2. upgrade dependencies (list below update with full)
    • bits-ui
  3. remove dependencies (list below update with full)
    • cmdk-sv
    • svelte-headless-table
  4. run npx sv migrate svelte-5 to migrate other components

@jakobpesch
Copy link
Contributor

jakobpesch commented Nov 5, 2024

You can also use both versions using npm aliases in your project and migrate only some components. It is a bit tedious and you gotta be careful to import from the correct version of bits-ui, but if you have a big project and don't want to do a huge migration, this could be an alternative.

@ieedan
Copy link
Contributor

ieedan commented Nov 5, 2024

I will work on an draft PR this morning with the initial things we discussed here I will reference this issue when I open it so we can continue discussion there.

@ieedan
Copy link
Contributor

ieedan commented Nov 5, 2024

Preview Documentation

Let me know what you think!

@jacob-winkler
Copy link

Preview Documentation

Let me know what you think!

I just used this to migrate. The guide is mostly great, well done and thank you!!

The one thing I noticed is the suggestion to use npx shadcn-svelte@next update. This command did nothing after I ran and selected the components I wanted to update. I instead ran npx shadcn-svelte@next add and selected the components I wanted to "install" which then overwrote my existing components

@ieedan
Copy link
Contributor

ieedan commented Nov 5, 2024

Correct this PR assumes that another PR #1421 merges. That fixes the update command.

@shubhamkumar13
Copy link

I had to manually install bits-ui@next with the latest version for anyone else having issues with the installation process

Thank you so much, Tauri right now has this same issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: help wanted This issue is tentatively accepted pending a volunteer committed to its implementation type: documentation A change or addition to the documentation
Projects
None yet
Development

No branches or pull requests

7 participants