A modern, feature-rich Electron kit for building cross-platform desktop applications with React and Vite
Features β’ Quick Start β’ Configuration β’ Contributing
The Reactronite is your ultimate starting point for creating modern, performant desktop applications. This carefully crafted template combines the power of Electron with the speed of Vite, the flexibility of React, and the safety of TypeScript to deliver an exceptional development experience.
- ποΈ Production-Ready Architecture - Clean, scalable project structure with separation of concerns
- β‘ Lightning Fast Development - Hot Module Replacement (HMR) with Vite for instant feedback
- π¨ Native Desktop Experience - Custom titlebar and native-feeling UI components
- π‘οΈ Type Safety First - Full TypeScript support with strict type checking
- π§ Developer Experience - Pre-configured linting, formatting, and git hooks
- π¦ Zero Configuration - Ready to code out of the box with sensible defaults
- Custom Titlebar - Native-looking titlebar with integrated window controls
- Responsive Design - Adaptive layouts that work across different screen sizes
- Modern Styling - TailwindCSS v4 styling system with theme support
- Cross-Platform Consistency - Unified experience across Windows, macOS, and Linux
- Hot Module Replacement - Instant updates during development
- TypeScript Integration - Full type safety with excellent IntelliSense support
- Code Quality Tools - Integrated ESLint and neostandard for linting
- Git Hooks - Automated code quality checks with Husky
- Path Mapping - Clean imports with TypeScript path resolution
- Secure IPC Communication - Safe main-renderer process communication
- Context Isolation - Properly isolated preload scripts
- Window State Management - Remembers window size, position, and state
- Auto-updater Ready - Built with Electron Forge for easy distribution
- Multi-Platform Building - Build for Windows, macOS, and Linux from any platform
- Optimized Bundles - Tree-shaking and code splitting for smaller app sizes
- Auto-Packaging - One-command building and packaging
- Distribution Ready - Pre-configured makers for various package formats
Make sure you have the following installed:
- Node.js (LTS or higher)
- pnpm (v10 or higher) - This project uses pnpm as the package manager
-
Clone the repository
git clone https://github.com/flaviodelgrosso/reactronite.git cd reactronite
-
Install dependencies
pnpm install
-
Start development
pnpm dev
That's it! Your application will launch in development mode with hot reloading enabled.
Command | Description |
---|---|
pnpm dev |
Start the app in development mode with hot reloading |
pnpm package |
Package the app for the current platform |
pnpm make |
Create distributable packages for the current platform |
pnpm publish |
Publish the app (configure publishers in forge.config.ts) |
βββ src/
β βββ main.ts # Main Electron process
β βββ preload.ts # Preload script for secure IPC
β βββ app/ # React application
β β βββ App.tsx # Main app component
β β βββ components/ # Reusable UI components
β β βββ screens/ # Application screens/pages
β βββ menu/ # Application menu configuration
β βββ ipc/ # IPC handlers and channels
β βββ @types/ # TypeScript declarations
βββ config/ # Vite configuration files
βββ assets/ # Static assets (icons, fonts, images)
The project uses Electron Forge for building and packaging. You can customize the build process by modifying:
forge.config.ts
- Main Forge configurationconfig/vite.*.config.ts
- Vite configurations for different processespackage.json
- Scripts and metadata
The boilerplate is designed to be easily extensible:
- New UI Components - Add to
src/app/components/
- New Screens - Add to
src/app/screens/
- IPC Channels - Define in
src/channels/
and handle insrc/ipc/
- Styling - Use TailwindCSS classes in your components or create custom styles in
src/app/styles/
We love contributions! Please see our Contributing Guide for details on:
- π Code of Conduct
- π Bug Reports
- π‘ Feature Requests
- π§ Development Setup
- π Pull Request Process
This project is licensed under the MIT License - feel free to use it for your own projects!
β Star this repo if you found it helpful!
Made with β€οΈ by Flavio Del Grosso