tastejs/todomvc — pull request #664 by smelnikov (2013-08-26 16:42:43+00:00)
Title: use fetch({reset:true}) for 2x-5x increase in rendering performance for backbone.

I'm not sure why, and I can't seem to reproduce a minimal test case but using reset:true seems to increase rendering performance about 2-3x on chrome (28) and 5x on firefox (23). Didn't test on any other browsers.

Here's my benchmark: (performed in console when backbone todos are open)

setup:
```javascript

function setup() {
for (var i=0; i<500; i++) app.todos.add({title: Math.random().toString()});
app.todos.each(function(m) {m.save()});
}

function time(reset) {
app.todos.reset();
var t = performance.now();
app.todos.fetch({reset: reset});
return performance.now() - t
}

setup();
```

timing:

```javascript
reset() //for reset : false
reset(true) //for reset: true
```

in chrome:

time()
529.0000000003492
time(true)
253.00000000058208

in firefox

time()
2093
time(true)
451

It was an accidental find and if anyone knows why it's happening (chrome timeline shows that a lot more time is spend parsing html) please fill me in :)