A minimal starter template for building desktop apps with Electron, React, TypeScript, and Vite, powered by Bun.
Includes hot reloading for both frontend and Electron, TypeScript compilation, and ESLint integration.
- React + TypeScript + Vite for fast HMR development
- Electron integration with a ready-to-use main process
- Bun for fast dependency management and script running
- ESLint setup for code quality and best practices
- One-command dev experience: compiles TypeScript, starts Vite, and launches Electron
- Install dependencies:
bun install- Run the development environment (React + Electron):
bun run devThis will automatically compile TypeScript, start the Vite dev server, and launch Electron with hot reloading.
- Build the app:
bun run build- Package your Electron app:
bun run dist:mac # macOS
bun run dist:win # Windows
bun run dist:linux # Linuxsrc/
├─ electron/ # Electron main process
├─ react/ # React frontend
dist/ # Built files
scripts/ # Helper scripts (e.g., dev-all.js)
package.json
tsconfig.json
vite.config.ts
- TypeScript-aware lint rules included
- React-specific lint rules via
eslint-plugin-react-xandeslint-plugin-react-dom - Extend or modify
.eslintrc.jsoreslint.config.jsfor stricter rules