ss-backbone
ss-backbone copied to clipboard
Need a way to signal collection sync completion
I am trying to read a model from a collection after fetching from the server. I can't figure out a way to be notified when the sync completes. It doesn't seem like you have implemented the standard Backbone.sync features related to this.
Backbone.sync should fire either options.success or options.error depending on whether the sync method succeeded.
Also, I should be able to listen to the sync event from my collection as per the documentation:
"sync" (model, resp, options) — when a model (or collection) has been successfully synced with the server.
I see the event "backbone-sync-model" is fired, but it occurs before the models are added to the collection. I need some sort of notification after the models have been added.