1. Vue version management
View the installable versions: npm view vue versions --json
Install the latest version (V3.2.45): npm install vue
Installation specification Version (V3.2.45): npm install [email protected]
View the installed version: npm list vue
Uninstall the installed version: npm uninstall vue< /span>
2. Vite version management
View the installable versions: npm view vite versions --json
Install the latest version (V3.2.4): npm install -g vite
Install the specified version (V3.2.3): npm install -g [email protected]
View the installed version: npm list vite
Uninstall the installed version: npm uninstall -g vite
3. vue-cli version management (below V3.0.0)
View the installable versions: npm view vue-cli versions --json
Install the latest version (V2.9.6): npm install -g vue-cli@latest
Install the specified version (V2.9.5): npm install -g [email protected] a>
View the installed version: vue -V
Uninstall the installed version: npm uninstall -g vue-cli
4. vue-cli version management (V3.0.0 and above)
View the installable versions: npm view @vue/cli versions --json< a i=2> Install the latest version (V5.0.8): npm install -g @vue/cli Install the specified version (V5.0.7): npm install -g @vue/[email protected]. 7 View the installed version: vue -V Uninstall the installed version: npm uninstall -g @vue/cli Comments : 1.Vite can only be used for Vue3; 2.Vue-cli: Versions below v4.5 correspond to Vue2; v4.5 and above The version corresponds to Vue3. Of course, you can also choose Vue2 when creating a project.