Offline-first modular Point of Sale system built with React + TypeScript + Electron + IndexedDB.
Runs as a desktop app (Windows portable) and a PWA in the browser β no internet required.
Create unlimited businesses with dedicated templates: POS, Restaurant, Dehydrated Foods, Fruit & Vegetable, Service Store.
- Quick item entry with auto-calculation
- Multiple transaction modes: Sale, Purchase, Expense, Production
- Invoice preview with print support
- WhatsApp receipt sharing
- Real-time stock tracking per product
- Low-stock alerts & negative stock prevention
- Inventory adjustments with reason logging
- Warehouse management with inter-warehouse transfers
- Fruver module: waste registration & freshness tracking
Track raw material β finished product conversion with:
- Yield percentage auto-calculation
- Batch history & cost tracking
- Per-batch metadata (weight, time, notes)
Complete service management:
- Client registration with WhatsApp contact
- Device & problem tracking
- Status workflow: Received β Diagnosing β Repairing β Ready β Delivered
- Cost & price estimation
Multi-device architecture for restaurants:
- Table management with move/merge support
- Kitchen view β real-time order status (pending β preparing β ready)
- Waiter station via browser on local network
- WebSocket-based real-time sync across devices
- Daily / Weekly / Monthly summaries
- Net profit calculation (revenue β costs)
- CSV export
- FREE plan: Sales + Inventory + Production + Export
- PRO plan: Everything + Expenses + Purchases + Config
- Offline grace period: 72 hours
- Device-based activation via Google Sheets
- Registration webhook with auto-licensing
| Layer | Technology |
|---|---|
| Frontend | React 19, TypeScript 6, Tailwind CSS 4, Vite 8 |
| Desktop | Electron 33, electron-builder (portable .exe) |
| Offline DB | IndexedDB via Dexie.js (schema v7) |
| Server | Express 5 (embedded in Electron) |
| Real-time | WebSocket (ws) for restaurant sync |
| PWA | Service Worker, manifest.json, offline-first |
| Licensing | Google Sheets API + Device ID |
| QR | QR code generation + payment QR |
βββββββββββββββββββββββββββββββββββββββββββββββ
β Electron β
β βββββββββββββββ ββββββββββββββββββ β
β β Vite/React ββββββββΊβ Express Server β β
β β (Renderer) β β (port 3456) β β
β ββββββββ¬ββββββββ βββββββββ¬βββββββββ β
β β β β
β βΌ βΌ β
β IndexedDB (Dexie.js) WebSocket Server β
β βββββββββββββββββββ ββββββββββββββββ β
β β 5 Business Types β β Real-time β β
β β 10+ Tables β β Sync (Mesas) β β
β β CRUD + Business β ββββββββββββββββ β
β β Logic β β
β βββββββββββββββββββ β
βββββββββββββββββββββββββββββββββββββββββββββββ
β² β²
β β
Browser (LAN) Browser (LAN)
(Waiter / Kitchen) (Another device)
- Node.js 20+
- npm
git clone https://github.com/maxtortecnoreparaciones/LionCore.git
cd LionCore
npm install
npm run dev # Web only at http://localhost:5173
npm run electron:dev # Desktop + Express servernpm run build # Web build (dist/)
npm run electron:build # Windows portable .exesrc/
βββ App.tsx # Main UI orchestrator (~1,739 lines)
βββ components/
β βββ layout/ # AppHeader
β βββ modals/ # 19 modal components (License, Payment, Product, etc.)
β βββ pos/ # TransactionForm
β βββ restaurant/ # 8 components (MesaCard, CocinaView, etc.)
β βββ views/ # 8 view components (History, Summary, Inventory, etc.)
βββ services/
β βββ db.ts # Dexie.js schema v7 + CRUD + business logic (~1,266 lines)
β βββ license.ts # License validation, device ID, plan management
β βββ registration.ts # User registration webhook
βββ utils/
βββ format.ts # formatCOP, formatDate, getTypeStyle
electron/
βββ main.js # Electron entry point
βββ server.js # Express + WebSocket + API endpoints
| Feature | FREE | PRO |
|---|---|---|
| Sales | β | β |
| Inventory | β | β |
| Production | β | β |
| Fruver Dashboard | β | β |
| Service Orders | β | β |
| Warehouses | β | β |
| Export CSV | β | β |
| Expenses | β | β |
| Purchases | β | β |
| Config (costs, margins) | β | β |
| Net Profit Reports | β | β |
npm run build # tsc + vite build β clean (cosmetic warnings only)| Version | Date | Highlights |
|---|---|---|
| 1.0.0 | 2026-05-02 | Initial release |
| 2.0.0 | 2026-05-20 | Full refactor: 37 components extracted from App.tsx, Kitchen status flow, Express v5, QR fix, Cash payment option |
- Fork the repo
- Create a feature branch (
git checkout -b feature/amazing) - Commit your changes (
git commit -m 'Add amazing feature') - Push (
git push origin feature/amazing) - Open a Pull Request
- WhatsApp: 313 877 7115
- GitHub Issues: Report a bug