0

私の見解では、複数のリスナーがinitializeいます。次のようになります。

this.collection.on('reset', this.render);

this.collection.on('add', this.render);

this.collection.on('change', this.render);

それらはすべて発砲するので、それらすべてを組み合わせる方法があるかどうか私は興味がありますrender

4

1 に答える 1

5

たぶんあなたは試すことができます

this.collection.on("reset add change", this.render);

これを見てください。そこに表示されているとおりに機能しますが、デフォルトのコレクションイベントとのバインドについてはよくわかりません。

于 2012-11-05T14:59:04.910 に答える