We can add query params in url simply by following simple rule.
<a [routerLink]="['product-list']" [queryParams]="{ page: 99 }">Go to Page 99</a>
With typescript we can do the same as below.
this.router.navigate(['/product-list'], {...
Read More ⟶
We can use route feature of angular to move from one component to another. The template way of using the route feature is as below.
<button class="btn btn-success" [routerLink]="['/dashboard', data1, data2, data3]">Continue</button>
We can route...
Read More ⟶
function CaesarCipher(str,num) {
if(num < 0) {
return CaesarCipher(str, num + 26);
}
let output = "";
for(let i=0; i<str.length; i++) {
let c = str[i];
if(c.match(/[a-z]/i)) {
let code = str.charCodeAt(i);
if(code >=...
Read More ⟶
This is how we query from mongodb collection to fetch data with total length, offset and limit. For total length we need to use async.
let url =...
Read More ⟶
We often need to modify the response that is return from the http request before it return as observable. That means before we parse it into our component we might need to update.
It all depends on the version of RxJs. Angular 6 launches with RxJs 6 - which means...
Read More ⟶