npm install express-generator -g Usage: express [options] [dir] Options: -h, –help output usage information –version output the version number -e, –ejs add ejs engine support
Asp.Net Serialize – Deserialize
1. How to convert .NET object to JSON string 2. How to convert a JSON string to .NET object We will be using the following
Javascript -1
Object The Object constructor creates an object wrapper. // Called as a constructor new Object([value]) The Object constructor creates an object wrapper for the given
Javascript 2
For of, For in – Loop var array = [70,50,40]; for(var i of array){ console.log(‘Values : ‘,i); } for(let i in array){ console.log(“Key / Index
Type of Observable Subscribe 3 – HttpClient Response Observable
Search Service import { Injectable } from ‘@angular/core’; import { SearchItem } from ‘./SearchItem’; import { HttpClient } from “@angular/common/http”; import { Observable, of }
Type of Observable Subscribe 2 – Of and Array
Create Observable from array using ‘of’ Operator Employee Service import { Injectable } from ‘@angular/core’; import { Employee } from ‘../models/employee.model’; import { Observable, of
Type of Observable Subscribe 1 – With CanActiveGuard
Employee Model export class Employee { id: number; name: string; gender: string; email?: string; phoneNumber?: number; contactPreference: string; dateOfBirth: Date; department: string; isActive: boolean; photoPath?:
Communicating Between Components with Observable & Subject – Angular 6
Observable.subscribe() The observable subscribe method is used by angular components to subscribe to messages that are sent to an observable. Subject.next() The subject next method
Angular CLI – 1
To create a new Angular Project : ng new MyFirstApp Run : ng serve –open Help Command : The output copied in the clipboard you
Async Pipe Angular
NgRx is the Angular state management libraries.NgRx expose application state in a form of a stream of state objects. This is usually implemented with the