Overview
Nanny-level detailed explanation, guide you to use Vite to create a Vue3 project , all you need is cv
Article directory
- Overview
- 1. Install Vite
- 2. Create a project
-
-
- 2.1 After running the above command, we will be asked to enter the project name. You can write a vue3-study
- 2.2 Select the project template, select Vue here, and press Enter to confirm
- 2.3 Select TypeScript and press Enter to confirm
- 2.4 Commands in sequence
- 2.5 Run the project
- 2.6 Project creation successful
-
1. Install Vite
Compatibility Note:
Vite requires Node.js version >= 12.0.0. I recommend using the v16 version of Node.js
Use npm:
npm init vite@latest
Use yarn:
yarn create vite
Use pnpm:
pnpm create vite
2. Create a project
npm create vite@latest
2.1 After running the above command, we will be asked to enter the project name. You can write a vue3-study
2.2 Select the project template, select Vue here, and press Enter to confirm
2.3 Select TypeScript and press Enter to confirm
2.4 Commands in sequence
- cd vue3-study (switch files to this folder)
- npm installl (install project dependencies)
- npm run dev (run the project)