Skip to content

etorhub/ant-design-boilerplate

Repository files navigation

React + TypeScript + Ant Design boilerplate

CI License: MIT Node npm

React TypeScript Vite Ant Design Redux Vitest ESLint

Minimal app: fetch data, list and filter with Ant Design Table. Stack: React 18, TypeScript, Vite, Redux + Redux-Saga, Reselect, Ant Design. Git hooks (Lefthook): pre-commit and pre-push run lint + tests.

Quick start

Node ≥18, npm ≥9.

git clone https://github.com/espinacs/ant-design-boilerplate
cd ant-design-boilerplate
npm install
npm start

Open http://localhost:8080.

Commands

Command Description
npm start Dev server (Vite)
npm run build Production build → dist/
npm run preview Preview production build
npm run clean Remove dist/
npm run lint ESLint (.ts, .tsx)
npm test Vitest (single run)
npm run test:watch Vitest watch
npm run coverage Coverage report → coverage/

Architecture (short)

  • React — UI; Main container + SearchBar + Ant Design Table.
  • Redux — Global state.
  • Redux-Saga — Async data fetch, dispatches success/error.
  • Reselect — Selectors from Redux state (components stay decoupled).
  • Ant Design — Components and styling.

Coverage: Vitest + v8; config in vite.config.ts. Report: npm run coverage → open coverage/index.html.

License

MIT.