This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
Currently, two official plugins are available:
Welcome to the React + Vite Template! This project provides a minimal setup to get React working with Vite, including support for Hot Module Replacement (HMR) and some ESLint rules.
To get started with this template, follow these steps:
Clone the repository:
git clone https://github.com/your-username/react-vite-template.git
Install the dependencies:
cd react-vite-template
npm install
Start the development server:
npm run dev
Your app will be running at http://localhost:5173/
.
In the project directory, you can run several scripts:
npm run dev
Runs the app in the development mode. Open http://localhost:5173 to view it in the browser. The page will reload if you make edits. You will see the console logs for Fast Refresh.
npm run build
Builds the app for production to the build
folder. Your app is ready to be deployed!
npm test
Launches the test runner in the interactive watch mode.
npm run lint
Lints the code and fixes some automatically.
npm run format
Formats the code using Prettier.
The project structure is as follows:
public
: Contains the static assets like index.html
and favicon.ico
.src
: Contains the source code of your app.components
: Contains the React components.pages
: Contains the app pages.styles
: Contains the CSS and other styles..eslintrc.js
: Contains the ESLint configuration.postcss.config.js
: Contains the PostCSS configuration.tailwind.config.js
: Contains the Tailwind CSS configuration.vite.config.js
: Contains the Vite configuration.Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
This project is licensed under the MIT License - see the LICENSE
file for details.