RxJS operators for Angular
RxJS operators for Angular
$ npm install --save ng-operators
import 'ng-operators/add/all';
response$.mapToResponseJson().subscribe(...);
import 'ng-operators/add/mapToResponseJson';
response$.mapToResponseJson().subscribe(...);
import { mapToResponseJson } from 'ng-operators';
mapToResponseJson.call(response$).subscribe(...);
mapToResponseJson<R>
Observable<http.Response>
Observable<R>
A shorthand of .map(resp => resp.json() as R)
mapToResponseText
Observable<http.Response>
Observable<string>
A shorthand of .map(resp => resp.text())
onNavigationEnd
Observable<router.Event>
Observable<router.NavigationEnd>
A shorthand of .filter(e => e instanceof NavigationEnd)
MIT