Daily iOS
Performance and debugging

React Native performance boundaries

A chat screen built with React Native is slow on iOS. How do you separate whether the bottleneck is JavaScript rendering, calls across the native boundary, or a native module?

How would an interviewer hear this answer? You'll see whether they'd move on, dig in, or say no, and which sentences would trip you up. Your score doesn't change.
See the short answer

First watch the JS thread FPS and UI thread FPS separately in the Perf Monitor to see which one drops. If JS drops, use the Hermes profiler in React Native DevTools to see which component render or JS function takes long; if UI drops, use Xcode Instruments Time Profiler on the native module or view hierarchy cost; and for the boundary between the two threads, count call frequency and payload size in logs to catch serialization cost.

Share a question