Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Add support for data-sort attribute #17

Closed
wants to merge 2 commits into from

2 participants

@xPaw
Collaborator

By adding data-sort="somecontent" to <td> element, it will be checked first, before getting contents of the element. Great for sorting numbers.

@tristen
Owner

Interesting. I'll review this soon!

@xPaw
Collaborator

Just wanted to say that I've been using this method across different tables, and it's working nicely

@tristen
Owner

@xPaw this looks cool. Can you make your changes to src/tablesort.js and rebuild the lib using grunt ?

Also if you could update readme.md under Additional Options with this? Additionally, there is a contributors array you should add your name to.

@xPaw
Collaborator

Is there any reason why there are 2 copies of the source?

@tristen
Owner

@xPaw there's only one source file and it exists in the src/ directory. I guess I could have called tablesort.js in the root tablesort.uncompressed.js

The one primary advantage to structuring your code in this was is that you can split up your spec into separate scripts within this src directory.

@xPaw
Collaborator

Ah, okay. I will do the changes to src file soon. I probably won't be able to compile with grunt (never used it, don't have too much time right now).

@xPaw xPaw closed this
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Dec 23, 2012
  1. Add support for 'data-sort' attribute, that overrides contents of ele…

    xPaw authored
    …ment
    
    Also, minor whitespace changes
Commits on Jan 8, 2013
  1. Make changes to actual source

    xPaw authored
Something went wrong with that request. Please try again.