Web Component: j-NativeNotifications


  • Info
  • HTML
  • JS
  • CSS
  • Meta

j-NativeNotifications

  • easy usage
  • singleton

Configuration

  • timeout {Number} needs to contain a timeout (milliseconds) for the expiration of notification (default: 8000)
  • icon {String} (optional) an icon (default /icon.png)

Methods

  • component.append(title, message, [callback], [icon]) for creating a new notification

Usage

SETTER('nativenotifications/show', 'TITLE', 'MESSAGE', function() {
    // optional, click
}, '/img/warning-optional.png');

Author