You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We spent nearly an hour to find out that automatic re-rendering of Collections does indeed work. We took so long, since the same Jasmine code to assert the changed DOM did not work on collections. (We mocked the AJAX call with a sync callback, so we assumed nothing is async).
However, after looking in the code, rendering of a single model is done in sync and rendering of a collection is done async (using debounce of UnderscoreJS).
I think it would be good to at least warn in the README about this behaviour to spare others the wasted time. Better yet, both update mechanisms should work the same way.
The text was updated successfully, but these errors were encountered:
I agree, I think we shouldn'the make promises on updating synchronously (react doesn'the really do this either). A warning would help. I'm not sure on making model asynchronous as well. It would make this problem more clear, but it would make debugging harder (I think). But a PR for an improved readme is very welcome of course
We spent nearly an hour to find out that automatic re-rendering of Collections does indeed work. We took so long, since the same Jasmine code to assert the changed DOM did not work on collections. (We mocked the AJAX call with a sync callback, so we assumed nothing is async).
However, after looking in the code, rendering of a single model is done in sync and rendering of a collection is done async (using
debounce
of UnderscoreJS).I think it would be good to at least warn in the README about this behaviour to spare others the wasted time. Better yet, both update mechanisms should work the same way.
The text was updated successfully, but these errors were encountered: