nathanreyes / v-calendar

An elegant calendar and datepicker plugin for Vue.
https://vcalendar.io
MIT License
4.4k stars 861 forks source link

Vue 3 support #633

Closed soullpoint closed 3 years ago

soullpoint commented 4 years ago

Hi, just wondering if you are planning to add support for Vue 3?

I don't seem to be able to use it in a new project I'm starting.

I'm getting an error "n.a.mixin is not a function" or something to that effect. If it's something I might be doing, please let me know!

Thanks for your work!

kylegosen commented 4 years ago

Wondering the same thing.

jlewin commented 4 years ago

I'm also hitting this same error in the browser when using vite and yarn

mits87 commented 4 years ago

Now the Vue3 was released so I'm looking forward to see an update of v-calendar.

swifthing commented 4 years ago

Same question here

rodrigomata commented 4 years ago

Same here, tried the next branch and same stuff

pgolemanov commented 4 years ago

Hi Nathan, could you please share with us if are planning to support Vue3. Thanks

dominykasgithub commented 4 years ago

would be great to have vue3

nataliawww commented 4 years ago

+1

santicros commented 4 years ago

+1 Hoping that will have support :)

thomasschaller1 commented 4 years ago

+1 Would be great

victor-gabou commented 3 years ago

+1

TWithers commented 3 years ago

+1

securedeveloper commented 3 years ago

+1

abunuwas commented 3 years ago

This needs fixing or this library will probably be dead soon, which is a pity

nathanreyes commented 3 years ago

Rest assured this is high on the priority list.

I don't know how to do plugins in Vue 3 yet, but I am going to try and learn this weekend and hopefully implement in a way that will integrate nicely with Vue 2, if possible.

nathanreyes commented 3 years ago

It doesn't look like supporting Vue 2 and 3 in the same build will be possible, or preferred at the least. My thinking is to start work on a Vue 3 compatible version on the next branch and publish a 3.0.0-alpha.0 as soon as possible. I have also wanted to convert this library to using Rollup as it will properly generate esm builds that is more easily consumed by applications. I'm sure that will be quite an intrusive endeavor, but hopefully not as difficult as it seems.

If anyone has any other recommendations or experience, please advise. Also, peep the next branch and issue a PR if you are willing to get in on the action 😄

Happy coding.

moutz commented 3 years ago

Hello, I wanted to watch if I can do something for helping in vue3 support. I pull the next branch but it looks like I can't build anything because of the vuepress dependency.

Also, what is the best way to dev/watch code in action using this repo ?

Thank you for your work, and this very usefull plugin.

jlewin commented 3 years ago

@nathanreyes - exciting to hear, thanks for the update.

Like @moutz I'd be interested in helping if I could sort out my roadblocks - any chance there's a dev discussion group or chat system where interested parties hang out?

nathanreyes commented 3 years ago

I'm doing experimental work on a separate repo just to get things working. It is a fork of another repo that had some things configured out of the box, like Rollup + PostCSS + Vue 3. Rollup Plugin Vue I think still has some bugs with using PostCSS in the style blocks.

I'm still debating creating a new repo since this is architecturally a whole new project. However, the issues and commit history would get lost out if I did that. 🤔

I have the most things working locally (sans DatePicker component)...I just haven't pushed the changes yet. Converting to Vue 3 was interesting. Most of the work was syntax changes with render functions (still not sure I'm crazy about using event handlers like onDayclick, it just looks kind of ugly to me). Also, some things need to be refactored to account for a lot of the deprecated features.

Here is an invite link to a discord server that I started a while ago but haven't shared with anyone yet. Anyone is free to join in. https://discord.gg/y4UmWeJp

michaelhays commented 3 years ago

Hey @nathanreyes, I'm getting an "Invite Invalid" on that Discord link.

nathanreyes commented 3 years ago

Oh. Here's a permanent link you can use. https://discord.gg/QrsUn4seXM

nathanreyes commented 3 years ago

Please reference the README on the next branch for testing Vue 3 compatibility issues. It uses Rollup so if you import in a module-bundler environment it should use the module build. UMD and CommonJS are also included but are not documented nor I haven't tested them much. It has Typescript support built in, but the types still need to be fleshed out. Just wanted to get it working for now.

Install using the next tag (v-calendar@next). 3.0.0-alpha.2 is the latest recommended version at this time.

I'd recommend reporting any quirks or bugs to the Discord channel for now in the vue3 channel since things are still fluid at the moment.

ryoha000 commented 3 years ago

I think there is a lack of type definitions for vue3. (Example: DatePicker)

nathanreyes commented 3 years ago

That is correct. They are still in work. Going to close this issue and recommend new requests be submitted as new issues.

ntdatstudy commented 3 years ago

hi @nathanreyes, I wanna override the content/events on weekdays by day-content slot template but it didn't work. How can I resolve it? Can you help me please? Thank you.