Trying to utilize the angular-confirm library, but finding its documentation unclear. Implementing it as shown below:
Library -
In button click (login.component.ts),
ButtonOnClickHandler() {
angular.module('myApp', ['cp.ngConfirm'])
.controller('myController', function($scope, $ngConfirm){
$scope.hey = 'Hello there!';
$ngConfirm({
title: 'What is up?',
content: 'Here goes a little content, <strong>{{hey}}</strong>',
contentUrl: 'template.html', // if contentUrl is provided, 'content' is ignored.
scope: $scope,
buttons: {
// long hand button definition
ok: {
text: 'ok!',
btnClass: 'btn-primary',
keys: ['enter'], // will trigger when enter is pressed
action: function(scope) {
$ngConfirm('the user clicked ok');
}
},
// short hand button definition
close: function(scope){
$ngConfirm('the user clicked close');
},
},
});
});
}
Resulting in the following error popup,
https://i.sstatic.net/PXc8k.png
Been searching for examples of successful implementations without luck. Any assistance in resolving this issue would be greatly appreciated!