Allocation of row ids.
Allocation of row ids.

I'm not crystal clear on how row ids are allocated by DT.
Is it the case that, if my table initialisation includes an explicit definition (e.g. rowId: "song_id"), then whenever that table is in play the numeric part of rowId is guaranteed to be the song_id?
That's the way it looks, but I want to be sure. I'm asking because I need more aspects of my app to become generic, and using row ids is a significant step.
This question has an accepted answers - jump to answer
This discussion has been closed.
Answers
Spot on.
If there is a valid value in whatever property the
rowId
property points to, then DataTables will assign that as the row DOM id. The default is to look in a property calledDT_RowId
. If there is no value in the property, then no row id is assigned automatically.Allan
Excellent! Many thanks Allan.