ducksboard / gridster.js

gridster.js is a jQuery plugin that makes building intuitive draggable layouts from elements spanning multiple columns
http://gridster.net/
MIT License
6.03k stars 1.2k forks source link

Serialize to get more data #519

Closed mnt closed 9 years ago

mnt commented 9 years ago

If possible it would be great to have gridster.serialize() to return more data which you may assign to the tags.

<li class="field" data-row="1" data-col="1" data-sizex="1" data-sizey="1" data-field="data-related">

At the moment it only returns

Object {col: 2, row: 1, size_x: 1, size_y: 1}

It would be great if I would be after calling gridster.serialize([field]) it would return:

Object {col: 2, row: 1, size_x: 1, size_y: 1, field: '''data-related"}