Ajo Alex
Posted on August 9, 2021
What is vite JS
Vite (French word for "fast") is a build tool that aims to provide a faster and leaner development experience for modern web projects.
Why we use Vite
Today most people use CRA
npx create-react-app
for starting a react project. Its very time consuming because it install many unused packages to the project.
Here, we use Vite for creating a react project. its less time consuming, because it only install necessary packages for the project.
When comparing to CRA, vite only take less time to start the server and updation.
So, here we start...
- Install react app using vite
npm init @vitejs/app my-react-app
- Choose the variant
Here vite asked for the app and varient. These are the technologies installed using vite js
- vanilla
- vanilla-ts
- vue
- vue-ts
- react
- react-ts
- preact
- preact-ts
- lit-element
- lit-element-ts
- svelte
- svelte-ts
Then Choose a variable and hit enter.
It create a folder named
my-react-app
and create the template files.
- change the directory
cd my-react-ap
- Intsall dependencies
npm install
or
npm i
- Run development server
npm run dev
Now we completed the installation.
Now you can open a editor and start the work.
💖 💪 🙅 🚩
Ajo Alex
Posted on August 9, 2021
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.
Related
javascript Built an AI tool to help my team tweet smart – goodbye manual posting, hello viral hits!🫡🚀
November 28, 2024
chainlink How to build a Lottery App with Solidity, Chainlink VRF V2.5 and React.js(Vite)
October 22, 2024