Spice Pavilion ROS — Offline-First Restaurant Operating System & POS
LAN-resilient restaurant POS, Kitchen Display System (KDS), and table management built with React 19, Dexie IndexedDB, Fastify 5, WebSockets, and SQLite WAL.
Current Implementation Status: Live login-protected deployment at casdotech.com/pos/ backed by React 19, Dexie IndexedDB, Fastify 5, and SQLite WAL architecture.

Industry Context & Problem Statement
High-turnover hospitality venues face severe operational disruption when internet-dependent cloud POS platforms freeze during dinner service—causing delayed kitchen tickets, billing queues, and order errors.
Cloud-only POS software introduces single points of failure whenever commercial ISP connections stutter during peak dining hours, stalling kitchen ticket printing and cashier checkout.
Proposed Solution & Technical Challenge
CASDO Technologies engineered Spice Pavilion ROS as a TypeScript monorepo combining a React 19 + Dexie IndexedDB touch client with a Fastify 5 + better-sqlite3 (SQLite WAL) backend and WebSocket KDS broadcasting.
Core Architectural Challenge
Architecting a dual-layer offline-first hospitality platform using browser IndexedDB (Dexie) on touch terminals paired with a local Fastify 5 + better-sqlite3 (SQLite WAL) backend and real-time WebSocket Kitchen Display routing so active dining service continues uninterrupted regardless of external broadband stability.
Architecture Breakdown
- Client Offline Store: Dexie IndexedDB layer caching active menus, table layouts, and pending order mutations inside touch terminals.
- Local Transactional Core: Fastify 5 server backed by better-sqlite3 in Write-Ahead Logging (WAL) mode for concurrent reads and atomic order writes.
- Real-Time KDS Messaging: @fastify/websocket event bus pushing order creation, modification, and kitchen completion states instantaneously across LAN screens.
- Auth & Security: @fastify/jwt role-based authentication separating cashier, kitchen, and manager permissions.
Implemented Technology Stack
- Frontend Monorepo (@ros/frontend): React 19, TypeScript 5.7, Vite 6, Dexie 4 (IndexedDB offline cache), Lucide Icons
- Backend Monorepo (@ros/backend): Node.js, Fastify 5.2, @fastify/websocket, @fastify/jwt, better-sqlite3 (SQLite WAL mode)
- Shared Contract Layer (@ros/shared): Shared TypeScript domain schemas ensuring compile-time API contract parity
- Deployment: Live hosted web demonstration & operational deployment at casdotech.com/pos/ plus local LAN restaurant execution mode
Implementation Methodology
- Structured as a clean npm workspaces monorepo sharing strict TypeScript domain types across frontend and backend.
- Built transactional SQLite WAL schema with seeded restaurant menu/table fixtures and automated backend tests.
- Deployed production build to casdotech.com/pos/ alongside local LAN server packaging.
Key Engineering Decisions
- Selected Fastify 5 + better-sqlite3 (synchronous C++ SQLite bindings in WAL mode) over heavy remote ORM stacks to achieve ultra-low transactional latency on compact local POS mini-PCs.
- Added Dexie IndexedDB on the React 19 client so even brief Wi-Fi dead zones between a waiter tablet and the LAN router do not drop order drafts.
Measured & Verified Outcomes
- Deployed live operational restaurant POS and management interface at https://casdotech.com/pos/.
- Engineered zero-cloud-dependency local LAN execution via SQLite Write-Ahead Logging (WAL) and Dexie IndexedDB browser caching.
- Implemented real-time WebSocket ticket dispatch connecting cashier/tableside terminals directly to Kitchen Display System (KDS) queues.
- Unified monorepo workspaces (@ros/shared, @ros/backend, @ros/frontend) with automated backend test verification and demo data seeding.
Known Limitations & Scope Boundaries
- •Live web instance at casdotech.com/pos/ is login-protected for operational security.
- •Direct ESC/POS USB/network thermal printer bridging requires a small local print-agent helper when running from a hosted HTTPS origin versus local LAN deployment.
Planned Roadmap Extensions
- → Multi-branch cloud aggregation dashboard consolidating daily Z-reports across franchise locations.
- → Automated supplier purchase orders triggered by recipe bill-of-materials depletion.
Related CASDO Engineering Services
Tailored multi-tenant platforms, domain-specific applications, and offline-resilient transactional backends engineered without rigid SaaS lock-in.
Fast, SEO-ready Next.js and React web platforms paired with offline-first Flutter mobile and desktop applications engineered for global audiences.
Domain-tailored inventory, procurement, billing, credit ledgers, and customer pipeline platforms replacing fragmented spreadsheets and rigid ERP licenses.
Related Engineering Solutions
Explore purpose-built industry and capability architectures engineered by CASDO Technologies.
Offline-First ERP, Accounting & LAN-Resilient POS
Transactional web, desktop, and mobile business systems backed by SQLite WAL, Dexie IndexedDB, and Flutter Hive so operations never freeze when WAN drops.
Custom Next.js E-Commerce & Full-Stack Web Platforms
Sub-second server-rendered web platforms, tailored checkout workflows, and scalable SQL backends free from bloated template plugins and recurring revenue tax.
On-Premise Hospital EMR & Clinical AI R&D
Sovereign clinical record deployments engineered for uninterrupted local hospital networks alongside transparent, non-clinical medical imaging research prototypes.