I have a current project in Vue 2. I saw Vue 3 was released in September ( https://news.vuejs.org/ ) and I'm wondering if there's a guide on how to upgrade. If there's no migration tool, is there a guide to manually upgrade and what steps to take?
4 Answers
In addition to the official guide @wittgenstein mentioned I found Evan You's talk at VueConf helpful. Also, reading through the Vue RFCs will help you understand the thinking behind many of the changes, which makes everything much clearer.
Comments
According to Evan You's talk at VueConf Amsterdam (september 2020):
- a migration build from V2 to V3 should be available for Q4 2020
- a "2.7 minor release backporting 3.x features and opting-in 3.x compatible behaviours and deprecation warnings", to smoothen the migration to Vue 3, is planned by 2021
Also, please note that even if Vue 3 is stable, it is not yet the case for the whole environment (for example, Vuex 4 and Vue-next-router are currently in RC), and some sub-projects may not be completely compatible with Vue 3 yet. A 'common switch' (Vue 3 and sub-projects) is also planned by 2021.
So, if your project is a large app, it is recommanded to wait for early 2021 to start the migration.
Comments
Check out the official documentation: https://v3-migration.vuejs.org/breaking-changes/introduction.html
Take in mind that there was some breaking changes, like Event Bus and Filters doesn't work any more in Vue3.
According to my understanding (I haven't worked with Vue3 yet) the migration is very easy. So you can still write Vue2 code as usual, even though you have Vue3 installed.