Skip to content

Conversation

@treygeorge
Copy link

My team needed a bit more information on the objects that we were sorting. We did this through data attributes on the li's. We thought it would be real nice to add that information automatically to the output object on toHierarchy. We thought other people might think it convenient as well.

All we did for was add a $.each().data() loop on the item passed into "toHierarchy". We can then loop through the captured items and add them to the currentItem object as properties.

Loving nestedSortable so far. It is working really well for us. Thanks!

treygeorge added 2 commits September 13, 2013 19:19
Trying to make the final object output a little bit more useful by
allowing the developer to define any data- attribute and have it added
to the final object.
Removed the jquery each and opted for JS for instead.  Also, some minor
formatting polish.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant