sumcumo / vue-datepicker

A datepicker Vue component. Compatible with Vue 2.x.
https://sumcumo.github.io/vue-datepicker/
Apache License 2.0
75 stars 22 forks source link

Use vite for dev #164

Closed mst101 closed 2 years ago

mst101 commented 2 years ago

This (at least) allows us to use vite to run the Demo pages while we're developing the vue 2 branch.

I reworked some of your 'vue3-support' code @MrWook to get the vite build process to work, but then abandoned the idea once I discovered that @vitejs/plugin-legacy is not compatible with vue2.

I also had a go at setting up vitest as an alternative to jest, but it seems that vitest uses a different coverage tool to jest (c8 instead of nyc) and this caused some inconsistencies in the reports. There is a debate going on currently within vitest as to whether to give the choice between c8 and nyc, but until that's resolved, I suspect we're probably best off sticking with jest.

As you can see I tried to upgrade jest to the latest version, but that failed because node 10 doesn't like globalThis.

Oh well, guess I'll get back to upgrading to vue 3...

MrWook commented 2 years ago

Seems fine to me but here are some changes from the previous PR so that should be merged first

MrWook commented 2 years ago

@mst101 with the jest update this one got some conflicts

mst101 commented 2 years ago

@MrWook - yay! Hope this one should be ok now...