ui icon indicating copy to clipboard operation
ui copied to clipboard

Long term maintainability

Open liamrohan opened this issue 2 years ago • 1 comments
trafficstars

Hi,

In terms of updating old components generated via CLI, would this have to be done with git by forking / cloning this repo and merging upstream changes here or?

Is there any recommendation for the best way to do this?

Ideal outcome: being able merge the latest changes from shadcn/ui to acme/ui somehow

Thanks :)

liamrohan avatar May 19 '23 16:05 liamrohan

@wondering2151 I'm looking into a solution for this. Either via documentation or the CLI.

Open to suggestions and ideas from the community.

shadcn avatar May 22 '23 07:05 shadcn

I think would be cool to give each component its own version. It could be stored in a comment in the file, or in components.json. When a change is made to a component upstream, its version will be bumped, and a command in CLI could check for new versions. I feel like this approach would be better than just diffing the code, because if you have custom changes in the components, it will cause troubles.

MaximMaximS avatar Jul 09 '23 16:07 MaximMaximS

I ran into a similar issue and ended up chaining diff and add commands for convenience. #941 Initially, I was maintaining an array of installed components (enhancing Add) and iterating through it, but using the diff command provided me with more detailed information.

ABrozovic avatar Jul 16 '23 20:07 ABrozovic

I ran into a similar issue and ended up chaining diff and add commands for convenience. #941 Initially, I was maintaining an array of installed components (enhancing Add) and iterating through it, but using the diff command provided me with more detailed information.

well it doesn't solve the issue if you have modified your components.

with the diff command its like a component library, but with extra steps :smile:

MaximMaximS avatar Jul 20 '23 10:07 MaximMaximS

I feel like this approach would be better than just diffing the code, because if you have custom changes in the components, it will cause troubles.

Agree with @MaximMaximS here. I ran into some issues with the experimental diff command due to stylistic differences. So diffing is kind of noisy for me and not too useful (it's saying all the components have updates but it's all just stylistic differences).

melanieseltzer avatar Aug 10 '23 23:08 melanieseltzer

@shadcn sorry for ping, but what do you think about this?

MaximMaximS avatar Sep 19 '23 15:09 MaximMaximS

This issue has been automatically closed because it received no activity for a while. If you think it was closed by accident, please leave a comment. Thank you.

shadcn avatar Jul 01 '24 23:07 shadcn