The recommended way to start a Vite-powered Vue project
To create a new Vue project using create-vue
, simply run the following command in your terminal:
npm create vue@latest
[!NOTE] (
@latest
or@legacy
) MUST NOT be omitted, otherwisenpm
may resolve to a cached and outdated version of the package.
Or, if you need to support IE11, you can create a Vue 2 project with:
npm create vue@legacy
[!WARNING]
Vue 2 Has Reached End of Life
Vite-Powered: Vue CLI is based on webpack, while create-vue
is based on Vite. Vite supports most of the configured conventions found in Vue CLI projects out of the box, and provides a significantly better development experience due to its extremely fast startup and hot-module replacement speed. Learn more about why we recommend Vite over webpack here.
Scaffolding Tool: Unlike Vue CLI, create-vue
itself is just a scaffolding tool. It creates a pre-configured project based on the features you choose, and delegates the rest to Vite. Projects scaffolded this way can directly leverage the Vite plugin ecosystem which is Rollup-compatible.
If you're transitioning from Vue CLI to Create Vue, we've got you covered. Here are some resources to help you with the migration: How to Migrate from Vue CLI to Vite
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。