Purpose & Overview
Enables asynchronous event dispatch to users, admin alerts, unread notification badges, and transactional notification history.
Installation & Setup
1
Install the package
bash
bun veap add @veap/notifications-plugin2
Register in lib/veap.ts (or auto via lib/plugins.gen.ts)
lib/veap.ts
typescript
// lib/veap.ts
import { Application } from "@veap/kernel";
import notificationsPlugin from "@veap/notifications-plugin";
export const app = Application.configure()
.withPlugins([notificationsPlugin])
.create();
// Dispatching a notification from a server action:
import { sendNotification } from "@veap/notifications-plugin";
await sendNotification({
userId: "user-uuid",
title: "Account Verified",
message: "Your profile has been successfully approved.",
type: "success"
});3
Start application
bash
bun devMigrations run automatically on boot via MigrationServiceProvider.
Keep in mind
- Integrates a notification bell directly into the @veap/panel-plugin header bar.
- Utilizes Sonner to display animated real-time toast notifications in the browser.
- Notifications are persisted in the database and synchronized in real time.
Dependencies
Veap Kernel
@veap/kernel (^0.1.0)
Required Veap Plugins
NPM Packages
date-fns@^4.1.0sonner@^2.0.0swr@^2.3.0lucide-react@^1.27.0
Authors & Maintainers
Veap Core Team
Maintainer