Use the Vite build tool to quickly create Vue projects

Compared with Webpack, Vite has the following characteristics

1. Fast cold start, no need to wait for packaging
2. Instant hot module update, real on-demand compilation, no need to wait for the entire project to compile

Vite build Vue project

Prerequisite: Install Node.js and Vite

The first step
is to create a Vite project through npm

npm init vite-app 项目名称

# 例如
npm init vite-app HelloVue

Step 2
When the project is successfully created, cd to the project directory

cd 项目名称

# 例如
cd HelloVue

The third step
is to install project dependencies

npm install

The fourth step
is to run the project

npm run dev

Guess you like

Origin blog.csdn.net/weixin_39927850/article/details/125144126