Pierzchała introduces React Compiler as a React Core Team project that automatically memoizes code so React can re-render less without code changes. In a sample app, a button and text input update separate pieces of state, but changing either initially causes unrelated components to render. React Native DevTools’ Highlight Updates setting makes those renders visible.
Auto Memoization in React Native? React Compiler Has You Covered
Speaker
Michał Pierzchała, principal engineer at Callstack, explains how to use React Compiler to reduce unnecessary re-renders in React Native in an episode of Callstack’s React Native Optimization in Practice series.
Pierzchała says the compiler can apply optimizations developers might otherwise add with React.memo, useMemo, or useCallback. He follows the React Native optimization guide, installs the compiler as a Babel plugin, and configures it to target React 19 in a project using React Native 0.79. He then clears Metro’s cache and restarts the app so the new Babel configuration takes effect.
After restarting, DevTools shows memo labels for the App, CountButton, and TextInput components. Updating the text no longer re-renders the button, and clicking the button does not re-render the text input. In the Profiler, Pierzchała records six commits and confirms that only the component whose props changed renders in the examples shown.
Pierzchała notes that React Compiler can be used in React Native as well as React web projects. He closes by encouraging developers to apply the setup and profiling techniques in their own projects.
Takeaways
- Use DevTools’ Highlight Updates to find components that render when unrelated state changes.
- React Compiler is configured as a Babel plugin; set its target to match the project’s React version.
- Clear Metro’s cache and restart after changing Babel configuration.
- Use the React Profiler to check whether memoization prevents unrelated components from rendering.
- Check compiler behavior in the app instead of assuming every render has been eliminated.
Mentioned in this talk
Search inside this talk
What was claimed 8
- role atMichał Pierzchała is principal engineer at
Callstack“a principal engineer at Callstack”
0:00inYour Android React Native App Is Big Because It's Missing This One SettingYouTube Verified5 sources· Talk
- featureReact Compiler: Automatically memoizes code to reduce React re-renders without changing the code
“enables React to re-render less without changing your code”
YouTube Unverified1 source· Talk
- usesReact Compiler uses Reacttargets React 19
“It works with and is compatible with React 19.”
2:16inReact Universe BriefingYouTube Verified2 sources· Talk
- built
“a book we wrote at Callstack about React Native optimization techniques”
YouTube Verified2 sources· Talk
- featureReact Native: The demonstrated project uses version 0.79
“uses React Native 0.79”
YouTube Unverified1 source· Talk
- integrates withReact Compiler integrates with BabelBabel plugin
“The compiler is actually a Babel plugin”
YouTube Unverified1 source· Talk
- featureReact DevTools: Shows memo labels for components auto-memoized by React Compiler
“we have memo labels showing that this component has been auto-memoized”
YouTube Unverified1 source· Talk
- metricReact Profiler: Six commits recorded
“The Profiler recorded six commits”
YouTube Unverified1 source· Talk











