Skip to content
RED SAGSkills
hardFrontend Developer interview question

A page must show a table with 50,000 rows and stay smooth while scrolling and filtering. How would you build it?

What the interviewer wants to hear

  • Virtualise rows so only visible rows are in the DOM
  • Paginate or stream data from the server where possible
  • Do heavy filtering and sorting off the main thread or on the server
  • Memoise rows and keep props stable
  • Use transitions or deferred values to keep input responsive
  • Handle accessibility and variable row heights

Model answer

Rendering 50,000 DOM rows will be slow, so the core idea is virtualisation: only render the rows visible in the viewport plus a small buffer, using a library like TanStack Virtual, and position them inside a tall scroll container. I would ask if the user really needs all rows on the client; often server-side pagination, filtering and sorting is better. If the data must be local, I move filtering and sorting to a Web Worker or use efficient indexes, so the main thread stays free. Rows are memoised with stable keys and callbacks. The filter input updates immediately while the list update uses useDeferredValue or startTransition. I also handle variable row heights by measuring, keep keyboard navigation and ARIA row counts correct, and profile with DevTools to confirm frames stay under 16ms.

Can you answer it under time pressure?

Take a timed hard round and get scored on every answer.

Start mock interview

More hard Frontend Developer questions