1.0.1 • Published 5 years ago

saytum-notice v1.0.1

Weekly downloads
-
License
MIT
Repository
-
Last release
5 years ago

Saytum notice

Using

Install the library

$ yarn add saytum-notice

Import the library and create an instance with settings

import SaytumNotice from 'saytum-notice'; 

new Notice({
  classNotice: 'notice',
  classActive: 'active',
  noticeDelay: 2100,
});

Add styles.

The observer monitors content changes inside the notification block and adds an active class.

Use the static method Notice.changeText() to change the text.

Notice.changeText({ selector = '.notice', text })