Different ways of injecting dependency in an AngularJS Application

When you start learning the very first characteristics of AngularJS, you may come across something called Dependency Injection (DI): the premise that AngularJS injects dependencies whenever an application needs them. As a developer, our task is only to pass the dependency to the module and everything else will be taken care by AngularJS. To create … Continue reading Different ways of injecting dependency in an AngularJS Application

Exploring Angular’s “Controller as” Syntax and the vm Variable

Read full article on the Infragistics blog Often, I hear developers ask “What is the ‘controller as’ syntax and how it is different from the $scope object approach of controller creation?” In this post we will learn about controller as syntax and compare it with the $scope object approach of controller creation. In AngularJS 1.2, … Continue reading Exploring Angular’s “Controller as” Syntax and the vm Variable

Understanding scopes in AngularJS custom Directives

Read full article on the Infragistics blog In this post we will learn about different kinds of scopes in AngularJS custom directives. First we’ll start with a high level introduction of directives and then focus on scopes. Directives Directives are one of the most important components of AngularJS 1.X, and have the following purposes: Gives … Continue reading Understanding scopes in AngularJS custom Directives