Directive That Injects a Modal $on Event in AngularJS -


how create directive injects fixed position modal or directly underneath element directive attached to? in directive want scope.$on trigger injecting directly below element.

here's code far:

angular.module('mobiledashboardapp')     .directive('httperrormessage', function (httperrors) {         return {             template: '<div></div>',             link: function(scope, element, attrs) {                 console.log("hello");                 scope.$on(httperrors.badrequest, function (event, args) {                     // inject template directly below 'element' <-- part i'm not sure how                 });             }         };     }); 


Comments

Popular posts from this blog

ruby - Trying to change last to "x"s to 23 -

jquery - Clone last and append item to closest class -

c - Unrecognised emulation mode: elf_i386 on MinGW32 -