Wauplin's picture
Wauplin HF Staff
frontend boilerplate
251d0f9 verified
|
raw
history blame
1.2 kB

React + TypeScript + Vite + Tailwind CSS

This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.

Tailwind CSS plugin has been configured for rapid UI development. You can start styling immediately using utility classes without writing custom CSS from scratch.

Getting started

Install dependencies

pnpm install

Run frontend (dev mode)

Run:

pnpm dev

Frontend website should be available on localhost:

  VITE v7.1.2  ready in 429 ms

  ➜  Local:   http://localhost:5173/
  ➜  Network: use --host to expose
  ➜  press h + enter to show help

Hot reload is enabled, meaning frontend is reloaded on each file update.

Code quality

You can run the linter with:

pnpm lint

and then test everything's fine with:

pnpm lint:check

And for code formatting, run:

pnpm format
pnpm format:check

Build

Finally, you can build you app using:

pnpm build

The generated website will be located in the dist/ folder.

To preview it, run:

pnpm preview

which serves the dist/ folder as a static site, simulating a production environment.