Category: Angular.js

What is the difference between $rootScope.$emit & $rootScope.$broadcast

Quick Recap of $scope $scope.$emit fires an event up to the parent $scopes. $scope.$broadcast fires an event down the $scope. Using $scope.$on we can listen for these events. $rootScope – The Problem Statement $rootScope has no $parent, hence using an $emit for most obvious reasons seems pointless. However,  a $rootScope.$emit(ted) event can only be caught by  $rootScope.$on listeners and not by $scope.on listeners. On…
Read more

Angular 1.6 rainbow-tsunami is out

New Features ngModelOptions: allow options to be inherited from ancestor ngModelOptions (296cfc, #10922) $compile: set preAssignBindingsEnabled to false by default (bcd0d4, #15352) jqLite: implement jqLite(f) as an alias to jqLite(document).ready(f) (369fb7) don’t throw for elements with missing getAttribute (4e6c14) don’t remove a boolean attribute for .attr(attrName, ”) (3faf45) remove the attribute for .attr(attribute, null) (4e3624)…
Read more