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

Move from Vue CLI to Vite #671

Open
matthew-white opened this issue Dec 4, 2022 · 0 comments
Open

Move from Vue CLI to Vite #671

matthew-white opened this issue Dec 4, 2022 · 0 comments
Assignees
Labels
high-priority infrastructure Low-level infrastructure, including the build

Comments

@matthew-white
Copy link
Member

Vue CLI is now in maintenance mode, so I think we should start planning to move to Vite.

Some of the performance issues described in Why Vite? sound familiar. In particular, right now it feels like build time is reducing the cadence of testing locally for us: even if tests themselves run quickly, it takes some seconds to start them.

I had interpreted a comment on a Vue I18n repository here as meaning that Vue I18n will stop working with Vue CLI. But looking at it slightly more closely, I think they're still planning to support webpack, just with something other than @intlify/vue-i18n-loader. Though as @sadiqkhoja has noted, vue-cli-plugin-i18n also doesn't seem to be well maintained.

We don't have much custom webpack configuration: I think what little there is is just in vue.config.js. Hopefully that will ease the transition to Vite.

Probably the hardest part of transitioning to Vite will be figuring out testing. Will we still be able to use Karma? Right now we use karma-webpack to get Karma working with webpack. Vite seems to use Rollup, and from a glance, there do seem to be ways to get Karma working with Rollup. That said, I have no particular love of Karma. Since Karma is no longer recommended within the Vue community, some testing things haven't always worked out-of-the-box for us. Looking at the Vue 3 testing guide, it looks like Vitest is the current recommendation. It'd be nice though if we could somehow sequence things so that we don't have to transition off Vue CLI and Karma at the same time. Could we move from Vue CLI to Vite in one step, initially setting up Karma to work with Rollup, then in a next step move from Karma to something like Vitest?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
high-priority infrastructure Low-level infrastructure, including the build
Projects
Status: ✏️ in progress
Development

No branches or pull requests

1 participant