Why is rowId a DOM element id instead of a data attribute?
Why is rowId a DOM element id instead of a data attribute?
creativetags
Posts: 2Questions: 1Answers: 0
Why <tr id="1" role="row"> and not <tr data-id="1" role="row">
This discussion has been closed.
Answers
To allow easy row selection with id values. You could use
createdRow
to assign a data property if you prefer.Allan
Chances are you want a numeric id which isn't valid HTML for the id attribute. Set it as a data attribute and that's not a problem.