Spend some time trying to figure out why my plunker doesn't work :(
https://plnkr.co/edit/JHODQeWQtYmz4UkYzFds?p=preview
error append on following line
let load = this.actions$.filter (action => return action.type==START_LOADING);
actions$ is defined like this :
private actions$ : BehaviorSubject<Action> = new BehaviorSubject<Action>({type: null, payload: null});
and I import this
import { Subject } from "rxjs/subject";
import { Observable } from "rxjs/Observable";
import { BehaviorSubject } from 'rxjs/subject/BehaviorSubject';
in debugger of Chrome, I see that some functions are available (map, lift, scan, etc) but not filter.
Somebody know why filter is not available on BehaviorSubject ? I imagine that is a simple mistake but I don't find it ;)
I think that you should import the filter
operator:
import 'rxjs/add/operator/filter';
Here is your updated plunkr with this import: https://plnkr.co/edit/37JEG4aQ7qmQuaPchB4Z?p=preview.
See this question for more details:
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With