sudheerpal / Learning-Angular2

Learning Module, Routing, Services , Components etc

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Personal Angular Notes

Architecture

Angular Architecture

Component

Annotations/Decorator add some metadata to our class. Why metadata? Simply it gives a meaning to our class.

Services

Services are injected to Components.

Once Services are injected, a component can then access the methods inside Services.

One way data binding

Two way data binding (using ngModel)

two way data Binding

Name
Here in above example we have assigned model.name value to the ngModel.

ngControl directive ensure the tracking of: the state change and validation of data within all form elements (html form element like input). We can call an element a control. Control = Element .

ngControl is used internally by all forms.

Each input element has an id property that is used by the label element's for attribute to match the label to its input control. Each input element has a name property that is required by Angular Forms to register the control with the form.

About

Learning Module, Routing, Services , Components etc

License:MIT License


Languages

Language:JavaScript 39.6%Language:TypeScript 35.5%Language:HTML 16.4%Language:CSS 8.4%