So I read this article about Angular 2 change detection, but after reading it I have got more confused, so I started reading some of the comments which led to more confusion.
I don't get it how Observables are quite different from Immutables and in this specific case of the Todo app, which approach is better?
Imagine that you have a tree of nodes, and each node has a bit that says "I may have changed". With Observable
, we are talking about events getting emitted; the event is dispatched up the tree. In other words:
Todo_ChangeDetector
would be flagged,Todos_ChangeDetector
would be flagged,App_ChangeDetector
would be flagged,Imagine you have 2 todo lists:
Which grocery list is active you are currently showing would be the Observable
; e.g. a dropdown, nav pills, etc. All the todo items under those 2 lists could be Immutable
; e.g. you are not the meeting organizer and cannot change the meetings.