jashkenas/backbone — pull request #3380 by fastest963 (2014-11-12 07:47:29+00:00)
Title: Added splice to collections

Adding `splice` to collections which is just a wrapper for slicing and then removing. Optionally also allows you to replace models just like `Array.prototype.splice`. Like `slice` it has the same arguments as `Array.prototype.splice`.

The only problem I see with this is that we don't have a good place to put `options`. We can't really just shove it on the end since we couldn't distinguish someone not passing options from someone passing an object that should be added. We could put it after `howMany` but that would break the format from being the same as `Array.prototype.splice`. I didn't put it anywhere for now, I thought I'd wait for others to weigh in.