INNER CODE UNIT · TypeScript

showNotification

radzionc/radzionkit · lib/ui/notifications/utils/index.ts:9

export const showNotification = (text: string) => {
  if (!areNotificationsAllowed()) return

  const notification = new window.Notification(text)
  notification.onclick = function () {
    window.focus()
    notification.close()
  }
}

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…