Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

cdl-notification

dev-users8MIT1.0.2TypeScript support: included

This is simple notification npm packege. We can use this packege to display INFO, WARN and ERROR type messages.

notifier, notification, toster, angular notifier, angular notification

readme

Notification

This is simple notification npm packege. We can use this packege to display INFO, WARN and ERROR type messages.

Installation instruction

npm install cdl-notification --save

Instruction to use the package

How to use?

Please follow below instruction to implement notification in your angular application.

//in module
import { NotificationModule } from 'cdl-notification'; 

imports: [
    NotificationModule
]

// In your component html file
<cdl-notification></cdl-notification>

// In your component ts file
import { MessageType, NotificationComponent } from 'cdl-notification';

export class AppComponent implements OnInit {

    @ViewChild(NotificationComponent, { static: true }) notifier: NotificationComponent;

    ngOnInit() {
        // To display Info message
        this.notifier.show(MessageType.INFO, 'This is simple info message');

        // To display Warn message
        this.notifier.show(MessageType.WARN, 'This is simple warn message');

        // To display Error message
        this.notifier.show(MessageType.ERROR, 'This is simple error message');
    }
}