-
Notifications
You must be signed in to change notification settings - Fork 27.1k
Closed
Labels
breaking changeseffort1: hoursrefactoringIssue that involves refactoring or code-cleanupIssue that involves refactoring or code-cleanup
Milestone
Description
As Http is Observable powered, it makes more semantic sense for requests to be "lazy", that is, nothing should happen until .subscribe is called somewhere downrange.
Currently, calling http.get(url) will immediately fire off an XHR, irrespective of whether or not the request has been subscribed to. This is probably a side-effect of the EventEmitter using a Subject (and thus could be resolved when RxNext goes in) - generally we should opt for Observables for such things and only use Subjects when necessary.
See http://plnkr.co/edit/ncg5Kx?p=preview for a reproduction / naive semantically better implementation.
Suggested fix would be having backends etc initialize and return an Observable that could be .mapped to the Response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
breaking changeseffort1: hoursrefactoringIssue that involves refactoring or code-cleanupIssue that involves refactoring or code-cleanup