📜  vite js - Shell-Bash (1)

📅  最后修改于: 2023-12-03 15:21:02.235000             🧑  作者: Mango

Vite.js - Shell-Bash

Vite.js is a build tool for modern web applications. It provides a fast and efficient development environment with features such as live-reload, hot-module-replacement and quick building.

Installation

To install Vite.js, you need to have Node.js installed on your machine.

npm install vite --global
Usage

To create a new project using Vite.js, you can run the following command:

vite create <project-name>

Vite.js also includes a dev server that can be started by running the following command:

vite

This will start a local server at http://localhost:3000 with live-reload and hot-module-replacement enabled.

Building for Production

To build your application for production, you can run the following command:

vite build

This will create a dist folder with optimized and minified assets ready for deployment.

Conclusion

Vite.js is a powerful tool for modern web development that provides fast and efficient building, live-reload and hot-module-replacement, making it an essential tool for any web developer.