useNotification
Native OS notifications.
const { showNotification } = useNotification()
| Member | Type |
|---|---|
showNotification | (options: { title: string; body: string }) => void |
import { useNotification } from 'nextop-app'const { showNotification } = useNotification()showNotification({ title: 'Done', body: 'Your export is ready.' })
Clicking the notification focuses/restores the main window. No-ops with a console warning if the desktop API is missing or the OS doesn't support notifications.