Level 2
someone can help please ?
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
I want to limit only 10 data perpage on jspdf ,only 10 rows data on 1 page , but didnt work .
i always use this autoTableAddPage , but its didnt work , i references from this link ,
and its my code
var res = doc.autoTableHtmlToJson(document.getElementById("basic-table"));
doc.autoTable(res.columns, res.data, {
drawRow: function(row) {
if (row.index > 0 && row.index % 10 === 0) {
doc.autoTableAddPage();
}
}
}, {margin: {top: 180},beforePageContent: header });
this data is showing but always more than 10 rows , whats wrong with this ? can someone help ?
Please or to participate in this conversation.