FormBuilder and FormArray are used for developing complex forms by reactive model approach in Angular 2. In complex forms usually we have dynamic grouping of controls based on business needs, For example populating the dynamic check boxes list and storing the states(checked/unchecked). FormArray - Array of FormControl instances. FormArray holds the aggregated behavior, like if … Continue reading Angular2 : Reactive Forms – Part 2
Category: Angular
Angular2 : Reactive Forms- Part 1
In angular latest version developments we have two ways of creating forms: Template Driven Model Driven ( Reactive) Major difference is that in reactive forms we don't use ngModel directive. In reactive forms there is no direct binding of object model to directives, rather we create our own model i.e. FormControl , FormGroup instances inside … Continue reading Angular2 : Reactive Forms- Part 1
Angular 2 : New Features
Key Feature Angular 2.0 : $scope is removed. Added logging service dairy.js TypeScript support: added @ annotation Added Routing supports JSON based configuration. Advantage: Support Browser compatibility(IE9 and above,Chrome..etc) and cross platform development. Also support Typescript, ES6, Dart. Fast loading by server pre -rendering, Offline compilation. DI injection.
Angular1.5 .Component() method
.component() Helper method. Allow developer to write in Angular 2 style to build and specify elements and logic on the page. Syntax compared to .directive: module. directive(name, fn); module. component(name, options); Arguments: name : Name of our component. options: Definition Object passed into the component. Example to create counter component: .directive('counter', function counter() { … Continue reading Angular1.5 .Component() method
Services In AngularJS
In AngularJS a Service is a component that do some specific work not like other services we assume to be get from web server. Services in AngularJS do lot many other stuffs. What Services in AngularJS do: # Services provide the reusable logic. # Simplify the code(controller) by putting some logic in the services. # Create shared … Continue reading Services In AngularJS
AngularJS Fundamentals
History: The AngularJS framework started as a project inside of Google, but it's now an open source project. Parent site https://angular.io AngularJS is a client side technology use to create single page application. i.e. no postback or page navigation like in Asp.net from Abc.aspx to Xyz.aspx, rather than we create a single shell/master page to load other web … Continue reading AngularJS Fundamentals