Hello Readers,
HTML is the best way of creating static documents, but  when we want to  create dynamic views in web-applications then we use javascript which is a client side scripting language, AngularJS  is a  framework of javascript used to create single page application. Using angular js you can add dynamic views in your HTML document for an  extraordinary expressive dynamic web application. 
 
Here are the few things about which we should have a clear concept before we start learning angular js i.e
directives, expressions, filters, modules, and controllers.
 
In  AngularJS directives play a major role as it is used to extend HTML with ng-directives.To understand  how we use directives go through this simple example of angularjs:
Note: AngularJS is a framework of  JavaScript, and it is distributed as a file of javascript so we need to  add this link(http://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js) to a web page with a script tag:
<script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script>
Here's the code
<div ng-app="" ng-init="Name='Pinky'">
<p>Name is <span ng-bind="Name"></span></p>
</div>
Output
 Name is Pinky
Here few ng-directives are used such as ng app, ng-init, ng-bind.I will discuss these directives in my next blog.
                       
                    
1 Comment(s)