carbon-components-vue icon indicating copy to clipboard operation
carbon-components-vue copied to clipboard

Support for Vue 3

Open layanto opened this issue 5 years ago • 7 comments

Is Vue 3 supported? Vue 3 is mostly backward compatible to Vue 2 so hopefully not too much effort to support Vue 3.

layanto avatar Sep 22 '20 09:09 layanto

With regards to Vue 3 support.

No firm plans or dates, depends on workload and Vue release dates. A final version of Vue 2 back-porting compatible features.

There are a number of things to consider: Should it be a typescript re-write? Should there be a Vue 2.x version? Should it be a bare minimum bump to support Vue 3. The current version has nothing like full test coverage. Should it before moving forward?

Probably a lot more too.

Given that Carbon/Vue is my side project and not the day job, I think the path forward is likely to be: If needed a 2.x version to remove any syntax not available in Vue 3. The last version of Vue 2 will contain support for some Vue 3 syntax. A bump of dependencies to Vue 3. Most of the current syntax will be compatible with Vue 3. Consider a Typescript vNext.

Contributors more than welcome on github for a Vue 3 version.

lee-chase avatar Sep 22 '20 09:09 lee-chase

Apologies for the possibly silly question.

Are all the carbon Vue components manually created based on the carbon Vanilla components or carbon React components? Or are they automatically converted/transformed from carbon Vanilla/React components? If manually created, how do you keep track of the changes done upstream in carbon Vanilla/React components so that the carbon Vue components are up to date? How do you make sure that each carbon Vue component behaves exactly the same as the corresponding carbon Vanilla/React component?

layanto avatar Sep 22 '20 11:09 layanto

When the project was started the Vanilla components were the canonical implementation. Since then the Carbon team has indicated that the React version is the canonical implementation.

I have largely kept pace with Carbon by

  1. Diffing the core vanilla and React source base between version tags.
  2. Addressing feature differences when issues are raised.

NOTE: I have not tried to copy the React implementation, instead preferring to implement in a "Vue" way. In general this means props, slots and events may differ but the function is the same.

If an effort to create a Vue 3 version is to be made I think the first step would be for myself or others to create an RFC issue to discuss.

lee-chase avatar Sep 22 '20 11:09 lee-chase

@lee-chase What is the current plan on supporting Vue3? Our organisation is planning to use Carbon components for the UI and we are very sure Typescript is mandatory. Since Vue3 is out and it has better typescript support now, we are exploring this. But if the UI library doesn't support it, then its a no no. So just wanted a update on your plans for this.

AshwinTayson avatar Dec 12 '20 18:12 AshwinTayson

Typescript is a possibility, although I believe the library could be updates to Support TS without being written in TS.

I hope to find time before the new year to write an RFC outlining plans for Vue 3.

lee-chase avatar Dec 12 '20 19:12 lee-chase

Thats awesome! Looking forward to this. I thought I'll need to write a new codebase thats entirely written on typescript with the new Vue 3.

AshwinTayson avatar Dec 12 '20 20:12 AshwinTayson

What's the status of the migration for Vue 3? So far there seem to be only a few components, judging by Storybook. I am in charge of the architecture of a large project and at this point we need to understand if adopting CDS with Vue isn't going to bite us back due to this port becoming an abandoned project.

Thanks for all the hard work!

sergiocastrovale avatar May 24 '22 13:05 sergiocastrovale

Hey just closing this one out. Vue 3 is well underway with guidance here: https://github.com/carbon-design-system/carbon-components-vue/tree/vNext#vue-3-guidance

The latest build can be installed with npm install @carbon/vue@next

davidnixon avatar Aug 07 '23 02:08 davidnixon