Skip to content

Instantly share code, notes, and snippets.

@ilyasozkurt
Created February 23, 2023 11:59
Show Gist options
  • Save ilyasozkurt/b19ece37ab6321d8ff2c43a94d6332a7 to your computer and use it in GitHub Desktop.
Save ilyasozkurt/b19ece37ab6321d8ff2c43a94d6332a7 to your computer and use it in GitHub Desktop.
function displayRows() {
const start = currentPage * rowsPerPage;
const end = start + rowsPerPage;
const rows = tbody.querySelectorAll("tr");
rows.forEach((row, index) => {
if (index < start || index >= end) {
row.style.display = "none";
} else {
row.style.display = "";
}
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment