0

I am implementing ngrx to existing web application and I asked myself the question is there a difference between the normal RxJs Observable and the return value of my store.select() function? And if there is a difference, can I convert my ngrx store value into a normal observable?

If I log both in the console I'm getting these two different descriptions:

  • the first log is the ngrx store value
  • the second one is the normal observable

Ngrx Observable vs Ng Observable

Thanks for your Help!! :)

Masood
  • 1,545
  • 1
  • 19
  • 30
  • No my problem is that i refactoring a function that used a observable and now i want to use my state variable which i thought is also a observable, but with the store.select method it doesnt work. Only with observable for example created with "of" – MarcelSauter Apr 22 '21 at 12:55
  • Then post the code of what really seems to be a problem. State indeed is a observable. You're probably just doing something else wrong. – kvetis Apr 22 '21 at 13:09
  • Ive posted another answer with 2 snippets – MarcelSauter Apr 22 '21 at 13:21
  • According to the docs, `select` does return an observable for each overload indeed. You probably have some error with your store https://ngrx.io/api/store/select – ShamPooSham Apr 22 '21 at 13:31
  • If you want to add new code, expand your question. – kvetis Apr 22 '21 at 16:34

0 Answers0