@app-elements/notification

3.0.2 • Public • Published

Notification

Displays a notification message.

Installation

npm install --save @app-elements/notification

Usage

import Notification, { showNotification } from '@app-elements/notification'

// Place in your root App component. Should only be rendered once in your DOM tree.
<Notification />

// To show a notification
showNotification({ message: 'PIRATES!' })

showNotification options

Prop Type Default Description
message String None The text to display in the notification
type Enum 'error' The class to use for the notication style. One of: [ 'error', 'warning', 'success' ]
length Number 3000 Time to keep the message displayed in milliseconds

Package Sidebar

Install

npm i @app-elements/notification

Weekly Downloads

0

Version

3.0.2

License

ISC

Unpacked Size

27.4 kB

Total Files

12

Last publish

Collaborators

  • coryschadt
  • trustfall
  • adriaanwm
  • staydecent