6 Nov

AngularJS–Introduction

Share Button

AngularJS is an open source javascript framework for creating Ajax based web apps. AngularJs aims to minimize the complexity involved in Ajax based apps. AngularJS comes with lot features, say two-way data binding, nice templating, easy REST interaction, custom component creation, multiple views, routing, and much more.

jQuery +  Angulajs is a great combination to create amazing web apps.

It supports test driven development. There is a chrome plugin  called Batarang which makes the debugging easy. AngularJs is top pick when it comes to single page application development.

Why is it called angular? HTML uses angle brackets, that’s the name.

Features of AngularJS

  • Two way Binding: This is the most powerful feature in AngularJS which syncs up the data between view and model. When model changes, it automatically changes the view and vice versa. This saves us from writing lot of code and DOM manipulations.
  • MVW Framework: Model View Whatever Framework which means both Model view controller and Model View View Model frameworks are applicable.
  • Routing Support: The current trend in web apps is single page apps where we don’t want users to navigate to  multiple pages, rather load everything on the same page on request.
  • HTML new syntax with directives: Makes UI creation simple and easy with new elements
  • Test Driven Development: It supports dependency injection which means the code is not in charge of obtaining its dependencies from another piece of code.

Download and installation

1.Download the script to server and point the script tag to it.

Non-Minified:

<script type=”text/javascript” src=”angular.js”/>

Minified:

<script type=”text/javascript” src=”angular.min.js”/>

2.Installation via CDN. Copy the below script in the <head> of html.

Non-Minified version of AngularJS can be used during development phase.

<script type=”text/javascript” src=” http://ajax.googleapis.com/ajax/libs/angularjs/1.2.16/angular.js”></script>

 

Minified version of AngularJS for production.

<script type=”text/javascript” src=” http://ajax.googleapis.com/ajax/libs/angularjs/1.2.16/angular.js”></script>
Share Button