AngularJs hide all alerts: Uncaught SyntaxError

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP



AngularJs hide all alerts: Uncaught SyntaxError



I have an angularJS component that displays alerts when something goes wrong while submitting, these alerts are not auto dismissed by design.



But, when the user fix all errors (there can be many alerts displayed on the screen) and submit I want to dismiss these alerts.



Based on this example https://jsfiddle.net/uberspeck/j46Yh/
I did something like this:


(function() !ctrl.password2 );.


});



And that is why indentation is so important.



Hope this may help you.





Yes was silly, but I copied as is from that example.
– zbeedatm
Aug 6 at 14:54





I still have one issue that alerts are not shown on the screen! I added the html to my post as well. It's not reaching this code: function AlertsCtrl($scope, alertsManager) $scope.alerts = alertsManager.alerts; ;
– zbeedatm
Aug 6 at 14:55






angular.js:14747 Error: [ng:areq] errors.angularjs.org/1.4.3/ng/…
– zbeedatm
Aug 6 at 15:10





You can not define AlertsCtrl in function style. Define same as addUserCtrl
– Hardik Shah
Aug 7 at 4:11


AlertsCtrl


addUserCtrl





Or define all controller in function style.
– Hardik Shah
Aug 7 at 4:13






By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Popular posts from this blog

Firebase Auth - with Email and Password - Check user already registered

Dynamically update html content plain JS

How to determine optimal route across keyboard