Example Page for Backbone Tablesorter

This is a lot of fun. See the readme for explanations.


Simple Use

Lets make a quick and easy example table. I don't even want to think about making columns, or figuring out datatypes. Also, lets display age before alphabet.
          var nameTable, names = [
            {name:'Bill',age:42},
            {name:'Jeff',age:19},
            {name:'Maggie',age:28}
          ];
          $(function(){
            nameTable = new BTS.SortableTable({
              el: $('#ageTable'),
              tableClass:'table table-bordered table-striped',
              collection: new BTS.SortableList(names)
            });
            nameTable.sortBy('age');
          });
        

Advanced use

Now for something completely different. Ahead we'll make a live updating twitter search by extending the SortableList class.

More Advanced

Lets blow our last example out of the water. I want to extend the SortableTable() class itself. I'm sick of these single state rows, I need something more dynamic. Behold the ExpandableTable() and Expanded Views