DEV Community

Cover image for React Interview Prep: Breaking Down the Core Fundamentals
Karthick (k)
Karthick (k)

Posted on

React Interview Prep: Breaking Down the Core Fundamentals

Mastering technical interviews isn't about cramming the night before—it's about building a consistent daily habit. As part of my daily 75-minute interview prep routine, I break down core React concepts into concise, high-impact answers.

Here is Part 1 of the core React concepts every developer should master for technical rounds.


1. What is React?

15-Second Answer:

"React is an open-source, component-based JavaScript library used for building fast, interactive user interfaces. It uses a Virtual DOM to optimise rendering by updating only the specific parts of the real DOM that change."

Key Interview Points

  • View Layer ($V$ in MVC): React only handles the UI layer, giving developers full flexibility over routing and state tools.
  • Declarative UI: You describe what the UI should look like for a given state, and React handles the DOM updates.

2. Library vs. Framework

15-Second Answer:

"The core difference is Inversion of Control. A framework dictates your architecture and calls your code, whereas a library like React gives you full control—you call it only when you need it."

Quick Comparison

  • Framework (e.g., Angular, Next.js): "Don't call us, we'll call you." It provides a pre-defined blueprint and architecture.
  • Library (e.g., React Core): A set of specialised tools focused strictly on rendering UI.

3. Virtual DOM & Reconciliation

15-Second Answer:

"The Virtual DOM is an in-memory representation of the real DOM. When state changes, React creates a new Virtual DOM tree, compares it with the previous one using a diffing algorithm, and patches only the changed nodes in the real DOM."

Reconciliation Workflow

Top comments (0)