API解释:
Creating a model will cause an immediate "add" event to be triggered on the collection, a "request" event as the new model is sent to the server, as well as a "sync" event, once the server has responded with the successful creation of the model.
从这段解释中能看出来触发的sync这个方法是collection的还是model的?我英语不太好,感觉这个描述不是很清楚啊。
根据:http://www.cnblogs.com/nuysoft/archive/2012/03/19/2404274.html的图示,似乎调用的是collection的sync方法,但是我没检测到有调用
backbone的collection的create方法的疑问?
- 写回答
- 好问题 0 提建议
- 追加酬金
- 关注问题
- 邀请回答
-