primefaces / primefaces/primereact

Datatable slow performance when selecting all items with checkbox

Open
#8,224 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Resolution: Stale Type: Performance
Dominant language
CSS
Stars
8.3k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

Describe the bug

When selecting all items using a datatable with 5k rows or more the page starts freezing. After a couple of seconds the items are selected. Using the paginator is also slow when all items are selected.

Reproducer

https://stackblitz.com/~/github.com/IndyNaessens/primereact-datatable-slow-selection-demo

System Information
System:
OS: Windows 10 22H2
CPU: (8) x64 11th Gen Intel(R) Core(TM) i7-1165G7 @ 2.80GHz
Memory: 11.29 GB / 31.74 GB
Binaries:
Node: 22.13.1 - C:\Program Files\nodejs\node.EXE
npm: 10.9.2 - C:\Program Files\nodejs\npm.CMD
Browsers:
Edge: Chromium (139.0.3405.102)
npmPackages:
primereact: 10.9.7
react: 19.1.1
Steps to reproduce the behavior
  • npm run build && npm start
  • go to http://localhost:3000
  • click on the select all checkbox in the datatable top left corner (increase from 5k to 10k rows if needed)
Expected behavior

Selecting all items should not freeze the current page.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked StackBlitz reproducer and the DataTable checkbox selection path, then run npm run build && npm start with 5k or more rows. Compare selecting all items and changing paginator pages, and verify that the current page no longer freezes or takes several seconds to update.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, react
Domain
frontend, performance
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Active
Clarity
Mostly clear
Newbie friendliness
65/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.