Visit the Github page for a demo
Download ngArise files from GitHub
bower install ngArise --save
Add the dependency ngArise
angular.module('app', ['ngArise']);
Add provider to make configurations (optional)
.config(['ariseProvider', function (ariseProvider) {
ariseProvider.setOptions(
{
title: 'Custom title'
message: 'Here a message',
templateUrl: 'path/to/views/message.html'
}
);
}]);
Inject Arise service to show / hide
.controller(['Arise', function(Arise) {
Arise.show();
// and / or
Arise.hide();
}]);
Place directive in html as element or attribute
<ng-arise></ng-arise>
<!-- or -->
<div ng-arise></div>
Options can be passed to configuration provider globally
The options list:
Option | Type | Default value | Description |
---|---|---|---|
title | String | "Please wait" | Message that is shown as H2 in default template |
message | String | "We're loading data" | String that is shown as a paragraph in default template |
templateUrl | String | "views/default.html" | Specify which template should be loaded |