The Trim Rows plugin allows trimming specific rows from the table. Rows being trimmed
aren't included in a
DataMap (gets by the
getData method) and they aren't
Note: If you need to exclude some rows from rendering, but keep them in a
use the HiddenRows plugin.
To enable the plugin, you need to set the
trimRows property to an array of row indexes.
See the examples section for a live demo.
Notice, that the second, third and sixth rows are missing.
You can access the plugin instance by calling
var plugin = hot.getPlugin('trimRows');
To trim a single row, call the
trimRow method of the plugin object:
To trim multiple rows, you can either pass them as arguments to the
trimRow method, or pass an array of indexes
plugin.trimRow(0, 4, 6); // or plugin.trimRows([0, 4, 6]);
To restore the trimmed row(s), use the following methods:
plugin.untrimRow(0, 4, 6);
plugin.untrimRows([0, 4, 6]);
To see the changes you made, call
hot.render(); to re-render the table.