Create package.json using following command with default settings npm init -y
TO install the Runtime dependencies npm install --save
Angular Decorators
- These are the objects used to define behavior for
- Class
- Property
- Method
- Following Decorators
- @NgModule
- Applied on class to define the class as Angular Module aka Contianer
- Properties of NgModule
- imports: Of the type array, this is used to load standard and external Angular module in the current Application
- declarations: Of the type array, this is used to declare references of all components, directives and pipes for the current application in the container provided by NgModule
- providers: Of the type array, this is used to initialize the Dependency container to register all Angular Services so that they can be injected in Components/Directives/Pipes etc
- bootstrap: Of the type array, this is used to define components to be bootstrap means rendered by the BrowserModule when the app is loaded.
- @Component
- Applied on class to make it as Angular Component
- @Injectable
- Applied on class to make it as Angular Service
- @Directive
- Applied on class to make it as Angular Directive
- @Pipe
- Applied on class to make it as Angular Pipe
- @Input
- Applied on Class property to accept data from the container
- @Output
- Applied on 'EventListener' to emit an event from child class to parent
- @HostListener
- Applied on method to host an event on the method, so that when an event is raised the method will be executed
- @NgModule
====================================================================================== Angular 'Ivy' compilation
- Combination of Ahead-of-Time (AoT) and HTML Markup compression
- Reduce the Production out put at an average by 80%
- Ivy aka the Next-Generation View-Engine
- Compile HTML Template into JSOM
========================================================================= Programming With Angualar
- Databinding
- Interpolation aka Expression Binding
- Read-Only Binding
- Syntax
- {{}}
- e.g. {{header}}
- Interpolation also evaluate Expression {{2+3}}
- Property Binding
- Binding public data member of Component with the Read/Write attribute of HTML element
- <input type="text" id="txt" name="t" [value]="">
- [value], [href], [checked], [disabled]
- Binding public data member of Component with the Read/Write attribute of HTML element
- Event Binding
- Binding a public method of the component with an event of HTML element
- <input type="button" value="Click Me" (click)="()">
- (click), (change) (keyup), (blur), ect
- Two-Way Binding
- Combination of Property Binding and EVent Binding
- [(ngModel)] = ""
- ngModel is a Attribute Directive of Angular that is used for Two-Way binding
- To Excute ngModel, please import FormsModule from @angular/form in @NgModule imports array
- ngModel
- Has 'ngModelChanged' event, this will be fired for the default event of UI element on wheich ngMOdel is applied e.g. keyUp event for input-text element
- Read the updated value of the element, it will pass the value to the component for the property being updated.
- Component will be updated and it will update all properties dependeing on the updated property
- Component will pass the updated value back to HTML UI and HTML UI will be updated
- Interpolation aka Expression Binding
- Component Communication
- HTTP Communication
- Angular Elements
- LitElements
- Angular Elements
- Micro-Front-Ends
- Cutomization
- Custom Directives
- Custom Decorators
- Custom Pipes
- NGRX
- Angular Testing
- Enzyme and Jest
- Using Gulp
- IOTA CSS
====================================================================== Angular Assignment 1 Create a Calculator like Windows Calculator