declare const Notification: any export const notify = (message: string) => { try { if (!('Notification' in window)) { return } else if (Notification.permission === 'granted') { new Notification(message) } else if (Notification.permission !== 'denied') { Notification.requestPermission((permission: any) => { if (!('permission' in Notification)) { Notification.permission = permission } if (permission === 'granted') { new Notification(message) } }) } } catch (error) { return } }