When I use $scope as injected into a controller, $toObservable gives me an Rx.Observable<T>.
However I have found that when i use the $toObservable on the scope passed into the link function of a directive, I get a different observable, namely an object with oldValue and newValue properties:
{ oldValue: T, newValue T}.
I feel that $toObservable should work consistently in these two situations. What do you think?
When I use
$scope
as injected into a controller,$toObservable
gives me anRx.Observable<T>
.However I have found that when i use the
$toObservable
on the scope passed into the link function of a directive, I get a different observable, namely an object witholdValue
andnewValue
properties:{ oldValue: T, newValue T}
.I feel that
$toObservable
should work consistently in these two situations. What do you think?