Backbone.ModelBinder
Backbone.ModelBinder copied to clipboard
why is auto_sort not by default on for collectionbinder?
It seems like it should be on by default. any reason why it's off? If I have a sorted collection and I add an item and the objects are reshuffled, I feel like collectionbinder should listen on that and reorder the child views. In a majority of use cases we'll have things like rows in a table, etc. which should be reordered if ordering is important.
This would also follow the default case of "doing the right thing with basic behavior". I can see corner cases for doing nice things like animated transitions, etc. that the user would have to write code for, but that's a corner case that can be enabled by turning off auto_sort for that case.
I agree. If you'd like, add it to the options, please test it out and do a pull request.
Makes sense to me. We've just wrapped all our calls to CollectionBinder and turned it on by default.
Yes, I'll pull request later tonight. Thanks!
Sorry, what's the build process to regen min.js? Not seeing anything...
Currently using http://jscompress.com/ for minification. Remember to preserve the comments at the top of the minified version and update the release version in both.
Sorry it took so long. Take a look, should be good.
I'm going to rewrite as per feedback, but it will take a couple days. Will repull request when I'm ready. PS I saw the travis build failed in the pull request, how do I run that locally?
@lastquestion
Don't worry about the travis build. I was having trouble getting PhantomJS hooked up and gave up.