bartcc/app.todos — Issue #5: Comparator in Backbone
Author: dgoujard
Created: 2011-10-18 12:08:58+00:00
State: open

Hello,
You have a little bug with comparator in Backbone. The order in you app is 0 1 **10 11 12** 2 You need to change you comparator in collection and set :

// Todos are sorted by their original insertion order.
comparator: function(todo) {
return Number(todo.get('order'));
}

Thank you for the sample !