What is AngularJS?:
Definition of angular:
according to official angularjs Documentation definition like this:”AngularJS is a structural framework for dynamic web apps. It lets you use HTML as your template language and lets you extend HTML’s syntax to express your application’s components clearly and succinctly”.
Features of AngularJS:
Using AngularJs we can create powerful Rich internet Applications.
3)Clean Way to write Client side Script.
5)AngularJs Support Clean MVC[Model View Controller] Way.
6)Web Application Developed in AngularJS Support Cross Browser Compatibility.
7)Open Source Technology.
8)Suitable For Large Scale Applications for maintaining clean MVC way & achieving high performance of application.
Core Features Of Angular JS :
we will See each and every key points in deails in our next subsequent chaptors.
Data Bindings is the automatic synchronization of data between the model and view components in angular applications angular supports two way data bindings due to this application developers save their time for developement.
AngularJs format the value of Expression for dispaying to user.
Directives in AngularJs are Powerful key components, it helps to extend basic elements/attributes [using class, CSS,attributes] create reusable and testable;e components.using Angular Directives we can create custom HTML tags, custom widgets.angular have its built in directives like ng-model,ng-bind…
AngularJS Temples written with HTML That Contains AngularJs Specific Components and structures.it render the view with information from the controller and model.template can be a single file or multiple views into one single.
Routing is Concept of Switching views from one to another.
Model View Whatever:
Model View Controller is modern Development pattern for separating the whole application into multiple parts like [model-database related operations,view-HTML layout, Controller- business logic].angularjs Does not implement MVC In Traditional Way but something to closer MVVM[Model View ViewModel].
Using Deep Linking You Can switch to particular page[its content] without traversing whole application from home page.due to deep linking it helps to index that particular page and get searching in search engines easily.
Dependency Injection :
Dependency Injection allows you to inject modules in Angular Controllers, Factory, services.using dependency injection you can traverse modules data among application.
Advantages of AngularJS:
1)Best Platform for creating Single page application in a clean way.
2)Data Binding capability
3) “Write less Do More” Developers can save time for writing the bulk of code using built in functionality.
4)Reusable Code Components..
3)Cross Browser Compatibility.
Disadvantages of AngularJS:
1)Application Written in AngularJS Not Secure,server side authentication required .
Basic AngularJS Program:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta name="generator" content="PSPad editor, www.pspad.com"> <title>Simple Angular JS Application GeekBaba</title> </head> <body> <div ng-app="my_app"> <!-- Angularjs Initilizations --> <p>Enter your Name: <input type="text" ng-model="name"></p> <p>Hello <span ng-bind="name"></span>! Welcoms TO Geekbaba</p> </div> <script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.15/angular.min.js"> </script> <script> var main_App=angular.module("my_app",); </script> </body> </html>