I have the following BehaviorSubject defined:
private posts = new BehaviorSubject<any[]>([]);
and on init:
ngOnInit() {
this.posts
.takeUntil(!this._postsLoaded)
.subscribe(x => {
this._postsLoaded = true;
// do something
});
}
But it gets the following error, although it should work:
Property 'takeUntil' does not exist on type 'BehaviorSubject<any>'