Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

AngularJS 2.0 HTTP does not update bindings unless the response logic is... #175

Open
kelf opened this issue Nov 22, 2015 · 1 comment
Open

Comments

@kelf
Copy link

kelf commented Nov 22, 2015

With ng2 xdomain properly intercepts HTTP requests. Unfortunately, it pulls any HTTP callback logic outside of the Angular "zone".

This is not necessarily a bug, but it is inconvenient, and very confusing at first. A good solution would be to provide an opportunity to inject a callback at xdomain config time, which would wrap the request's success callback.

Using this, an end-user can configure xdomain to automatically instantiate and wrap the logic in a zone.run(...).

@jpillora
Copy link
Owner

I'm not very familiar with angular 2.0 zones. I vague understand it to be wrapping all JS runtime async functions (setTimeout, setInterval, XMLHttpRequest, etc). This is an XHook issue so I've recreated it there, not sure when I'll get to time to debug this though... Locked, please continue discussion here jpillora/xhook#40

Repository owner locked and limited conversation to collaborators Dec 27, 2015
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants