CLI Configuration and Plugins
Configure the CLI and add plugins to extend your project.
Configuring Your Build
Both Vue CLI and Vite let you customize the build through a config file.
- Vue CLI uses vue.config.js
- Vite uses vite.config.js
Here you add plugins, set aliases, configure the dev server, and more.
vite.config.js Basics
A typical vite.config.js imports the Vue plugin and exports a config object.
import { defineConfig } from "vite"
import vue from "@vitejs/plugin-vue"
export default defineConfig({
plugins: [vue()],
server: {
port: 3000
}
})All lessons in this course
- Vue CLI Installation
- Generated Project Structure
- CLI Configuration and Plugins