React · Middle · Question 31 of 75

What does the React Compiler do?

Explanation

The compiler analyzes code and inserts memoization itself, so manual useMemo, useCallback and memo are mostly unnecessary. It relies on the rules of React (pure renders, immutability) and skips components that break them. In Next.js 16 it's enabled with the reactCompiler option.

Further reading

Problem with a question

React · Middle · question 31

Test yourself

Take the React · Middle quiz: questions and options are shuffled, and you get a review of your mistakes at the end.

Take this quiz