PracHub
QuestionsPremiumLearningGuidesCheatsheetNEWCoaches
|Home/Other / Miscellaneous/Meta

Implement, Debug, and Optimize a React Table

Last updated: Mar 29, 2026

Quick Overview

This question evaluates a developer's competence in React component design, state ownership (controlled vs. uncontrolled), dynamic column rendering, client-side pagination and sorting, component decomposition, responsiveness, extensibility, and performance debugging.

  • hard
  • Meta
  • Other / Miscellaneous
  • Software Engineer

Implement, Debug, and Optimize a React Table

Company: Meta

Role: Software Engineer

Category: Other / Miscellaneous

Difficulty: hard

Interview Round: Technical Screen

Design and implement a reusable Table component in React that supports client-side pagination and column sorting. The table must accept dynamic columns via a columns prop (with accessors and optional custom cell renderers). Decompose the UI into clear subcomponents (e.g., Table, Header, Body, Row, Cell, Pagination) and justify your state design (what lives locally vs. in a parent; controlled vs. uncontrolled props). Follow-ups: 1) Explain how you would make the component extensible (e.g., plug-in hooks for custom sorting/pagination, server-side data mode) and how you would evolve the API without breaking changes. 2) Describe how you would support a mobile responsive layout (e.g., column priority, stacking, or horizontal scroll) and the trade-offs of each. Debug/Performance task: Given an existing React table implementation, identify and fix: a) unnecessary re-renders, b) event binding leaks, and c) misaligned rendering (rows/headers out of sync). Explain how you would detect each issue (e.g., React DevTools Profiler) and the specific code changes you would make (memoization with React.memo/useMemo, stable callbacks with useCallback/useRef, correct keys, proper effect cleanup). Bonus: The table feels very janky under heavy data. Describe a concrete optimization plan: measurement and profiling steps, reducing render work, memoization strategy and dependency hygiene, list virtualization/windowing, batching/debouncing of expensive updates, and how React's shallow comparison and reconciliation influence your approach.

Quick Answer: This question evaluates a developer's competence in React component design, state ownership (controlled vs. uncontrolled), dynamic column rendering, client-side pagination and sorting, component decomposition, responsiveness, extensibility, and performance debugging.

Related Interview Questions

  • Design unit tests for grid navigation - Meta (medium)
Meta logo
Meta
Aug 1, 2025, 12:00 AM
Software Engineer
Technical Screen
Other / Miscellaneous
4
0

React Table Component — Design, Implementation, and Performance

Context: You are building a reusable React Table component for a frontend technical screen. The table should accept dynamic column definitions, support client-side sorting and pagination, and be decomposed into clear subcomponents. You must also explain state ownership (local vs. parent) and controlled vs. uncontrolled props. After the base implementation, address extensibility, responsiveness, debugging, and performance.

Requirements

  • Build a reusable Table component with:
    • Client-side pagination and column sorting.
    • Dynamic columns via a columns prop, with accessors and optional custom cell renderers.
    • Decomposed UI subcomponents: Table, Header, Body, Row, Cell, Pagination.
    • Justification of state design: what is local, what is controlled by a parent.

Follow-ups

  1. Extensibility:
    • How to support plug-in hooks for custom sorting/pagination.
    • How to add a server-side data mode.
    • How to evolve the API without breaking changes.
  2. Mobile responsiveness:
    • Support approaches like column priority, stacking, or horizontal scroll.
    • Explain trade-offs of each.

Debug/Performance Task

Given an existing React table implementation, identify and fix:

  • (a) Unnecessary re-renders.
  • (b) Event binding leaks.
  • (c) Misaligned rendering (rows/headers out of sync).

Explain how to detect each (e.g., React DevTools Profiler) and the specific code changes you would make (memoization with React.memo/useMemo, stable callbacks with useCallback/useRef, correct keys, proper effect cleanup).

Bonus

The table feels janky under heavy data. Provide a concrete optimization plan:

  • Measurement and profiling steps.
  • Reducing render work and memoization strategy (dependency hygiene).
  • List virtualization/windowing.
  • Batching/debouncing expensive updates.
  • How React's shallow comparison and reconciliation influence your approach.

Solution

Show

Comments (0)

Sign in to leave a comment

Loading comments...

Browse More Questions

More Other / Miscellaneous•More Meta•More Software Engineer•Meta Software Engineer•Meta Other / Miscellaneous•Software Engineer Other / Miscellaneous
PracHub

Master your tech interviews with 7,500+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.