A CARE frontend plugin that provides in-app notifications and web push notification support. Need backend plugin care_notifications_be enabled for this.
- In-App Notifications — Real-time notification feed with polling, read/unread management, and filtering
- Web Push Notifications — Browser push notification support via the Web Push API (VAPID)
- Notification Bell Icon — Nav bar icon with unread badge count
- Filtering & Ordering — Filter notifications by event type, resource type, facility, and read status
| Category | Events |
|---|---|
| Bookings | Confirmation, Reminder, Cancellation, Reschedule |
| Diagnostics | Report Ready |
| Service Requests | Raised |
| Encounters | IP Created |
| Medication Stock | Near Expiry, Low Stock |
- Node.js v22+
- A running instance of Care Frontend
npm installStart the dev server with hot-reload (builds on file change and serves via Vite preview):
npm startThe plugin will be served at http://localhost:10125.
npm run buildThe output is written to dist/ with remoteEntry.js as the module federation entry point.
| Script | Description |
|---|---|
npm start |
Build in watch mode and serve via Vite preview |
npm run build |
Production build |
npm run lint |
Run ESLint |
npm run lint-fix |
Run ESLint with auto-fix |
npm run format |
Format code with Prettier |
npm run sort-locales |
Sort locale JSON files alphabetically |
{
"url": "http://localhost:10125/assets/remoteEntry.js",
"config": {
"NOTIFICATION_POLL_INTERVAL": "1000"
},
"name": "care_notifications_fe"
}This plugin uses Module Federation to expose its manifest to the Care frontend host. The manifest registers:
- Routes —
/facility/:facilityId/notificationsand/facility/:facilityId/users/:user/notifications - Nav Items — Notification bell icon in the sidebar and user menu
To connect the plugin to Care, add the plugin's remote entry URL to the Care frontend configuration.
To enable browser push notifications for your device:
- Click your user/profile icon in the sidebar
- Select Notifications from the menu
- Click the Enable button
- Allow the browser permission prompt when asked
Once registered, you will receive push notifications even when the app is not actively open in your browser.