Build Guide / 02
Technology stack
Every library in package.json earns its place — there's no
generic starter-kit filler. Grouped by the job each one does.
Core framework
| Library | Role |
| react / react-dom 19 | UI runtime |
| typescript ~5.8 | Type safety across ~90 page modules |
| vite 6 + @vitejs/plugin-react | Dev server and production bundler |
| react-router-dom 7 | Client-side routing across 231 routes |
| express 4 | Dev server middleware host + production API |
| tsx | Runs the TypeScript server directly in dev, no separate compile step |
| esbuild | Bundles server.ts to a single CommonJS file for deploy |
Styling & UI
| Library | Role |
| tailwindcss 4 + @tailwindcss/vite | Utility-first styling, compiled by the Vite plugin (no separate PostCSS config) |
| shadcn + Radix primitives (radio-group, etc.) | Accessible unstyled component primitives under components/ui |
| class-variance-authority, clsx, tailwind-merge | Composing conditional Tailwind class strings safely |
| lucide-react | Icon set used throughout every module |
| framer-motion / motion | Transitions — modals, panel reveals, status changes |
| @fontsource-variable/geist, tw-animate-css | Self-hosted variable font + animation utility classes |
Data & platform
| Library | Role |
| firebase 11 | Client SDK: Auth, Firestore, real-time listeners |
| firebase-admin 13 | Server-side privileged access for cron jobs and admin operations |
| @google/genai | Gemini API client behind the in-app AI assistant |
| node-cron | Drives the daily automatic IPD bed-charge job |
| resend | Transactional email (referral notices, reports) |
| serverless-http | Adapts the Express app to run inside a Netlify Function |
Domain-specific tooling
| Library | Role |
| cornerstone-core, cornerstone-wado-image-loader, dicom-parser | Rendering DICOM medical images for the Radiology module |
| jspdf, jspdf-autotable, html2canvas, modern-screenshot, react-to-print | Generating and printing invoices, prescriptions and reports |
| qrcode.react, react-barcode, react-qr-code | Patient/sample identifiers on printed labels and invoices |
| xlsx | Exporting reports (accounts, HR, stores) to Excel |
| recharts | Dashboards — MIS, accounts, occupancy charts |
| dompurify | Sanitizing any HTML rendered from stored user input |
| date-fns | Date arithmetic for shifts, billing periods, leave |
Deployment target
The app deploys to Netlify: static assets from dist/,
API routes proxied to a single Netlify Function
(netlify/functions/api.ts), and a catch-all rewrite so client-side
routing works on refresh. See Build &
Deployment for the full pipeline.