Skip to content

Instantly share code, notes, and snippets.

@rajaramtt
Created December 17, 2018 13:58
Show Gist options
  • Save rajaramtt/dbe997ee9dca9717602eafa753ca8312 to your computer and use it in GitHub Desktop.
Save rajaramtt/dbe997ee9dca9717602eafa753ca8312 to your computer and use it in GitHub Desktop.
Observable map key example
import { Observable, BehaviorSubject, ReplaySubject, pipe } from 'rxjs';
import { of as observableOf } from 'rxjs';
import { tap, map } from 'rxjs/operators';
import { distinctUntilChanged } from 'rxjs/operators';
return this.http.post(`${environment.host}${environment.loginService}`, credentials)
.pipe(
map(response => {
const storage = sessionStorage;
return response['userDetails'];
}));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment