Skip to content
This repository has been archived by the owner on Apr 20, 2018. It is now read-only.

Behaviour subject called twice so backend service called twice ? #1523

Open
suresh2018 opened this issue Oct 30, 2017 · 4 comments
Open

Behaviour subject called twice so backend service called twice ? #1523

suresh2018 opened this issue Oct 30, 2017 · 4 comments

Comments

@suresh2018
Copy link

suresh2018 commented Oct 30, 2017

storeFillterData: Subject = new BehaviorSubject(null);
getFillterData() {
return this.storeFillterData;
}

updateFillterData(data: object) {
this.storeFillterData.next(data);
}

@suresh2018 suresh2018 changed the title Behaviour subject called twice ? Behaviour subject called twice so backend service called twice ? Oct 30, 2017
@zjuasmn
Copy link

zjuasmn commented Nov 6, 2017

BehaviorSubject will emit its current value once subscribed, maybe you would want to add .skip(1) to it

@suresh2018
Copy link
Author

suresh2018 commented Nov 6, 2017 via email

@suresh2018
Copy link
Author

suresh2018 commented Nov 6, 2017 via email

@suresh2018
Copy link
Author

Not working

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants