ngx-alertify
v0.0.8
Published
This lib support Angular6+ only
Downloads
8
Readme
About this lib
This lib support Angular6+ only
it is a wrapper of alertify.js.
Install
npm install ngx-alertify
npm install alertifyjs
add the following style and js to angular.json file:
{
...
"projects": {
...
"architect": {
"build": {
...
"styles": [
...
"node_modules/alertifyjs/build/css/alertify.min.css",
"node_modules/alertifyjs/build/css/themes/bootstrap.min.css",
"node_modules/alertifyjs/build/css/themes/semantic.min.css"
],
"scripts": [
"node_modules/alertifyjs/build/alertify.min.js"
]
},
...
}
}
}
}
}
4.Inject service to you component where needed
export class AppComponent {
constructor(private alertifyService: NgxAlertifyService) {
alertifyService.success('sucess');
}
}
- Call the method by
alertifyService.success('sucess');