Duminy describes Android startup times reaching about 30 seconds on popular low-end devices. The team measured the boot sequence, parallelized work, improved a slow Keychain path, and switched from Metro to Re.Pack for code splitting and tree shaking. Startup time fell below three seconds. The team later made time to interactive a KPI and emphasized automating and tracking important metrics.
Hard-learned Lessons in App Scaling
Speaker
Mike Duminy, principal engineer and architect at Klar, shares lessons from scaling the Klar app at React Universe Conf 2024, presented by Callstack.
A feature that downloaded a website at app startup began making about 800 requests after a webpack chunking change, starving other app requests. The feature team had used an available startup callback to preload its content. Duminy’s lesson is to design APIs defensively and limit access to risky ones with tools such as code ownership or lint checks.
The team’s move from a monolithic app to Yarn workspaces took two and a half years across roughly two million lines of code and 200 features. The final 10 percent took about a third of the project time. Allowing old and new architectures to interoperate let teams migrate gradually, while CI rules for new code and communicating team benefits helped adoption.
A development-only recursion error blocked more than 300 developers, but git bisect and reverting the apparent commit did not identify the cause. The team reproduced the issue with a generated bundle of about 50,000 connected files and shared it with the Hermes team. They traced it to a memory limit in register allocation; the issue was fixed in React Native 0.75. Duminy recommends digging into tools and working with their open-source communities when familiar debugging resources fall short.
Takeaways
- Choose critical performance metrics, automate their measurement, and connect them to business goals.
- Treat every platform API as something feature teams may use in unexpected ways; restrict risky entry points.
- Plan large migrations for gradual adoption, with old and new systems able to coexist.
- When a bug has no clear cause, build a small reproduction and bring concrete evidence to the tool’s maintainers.
Mentioned in this talk
Search inside this talk
What was claimed 11
- useswraps webpack under the hood
“With Re.Pack, you can use webpack”
0:28inHow to build super apps with React Native and Re.Pack?YouTube Verified7 sources· Talk
- usesKlar app uses React Nativebuilt almost entirely in React Native
“for the past three-plus years I’ve mainly been using React Native as my tool of choice”
0:36inGraphQLifying React Native AppYouTube Verified2 sources· Talk
- metricKlar app: About 85 million downloads
“something like 85 million app downloads”
YouTube Unverified1 source· Talk
- metricKlar app: 30 million monthly active users
“We've got 30 million monthly active users”
YouTube Unverified1 source· Talk
- built
“scaling our Klar app”
YouTube Unverified1 source· Talk
- role atMike Duminy is principal engineer and architect at Klar
“I'm a principal engineer and architect at Klar.”
YouTube Unverified1 source· Talk
- built
“Re.Pack is a direct successor to Haul. Haul was also an open-source project that we created here at Callstack.”
1:28inRe.Pack - bringing Webpack to React NativeYouTube Verified2 sources· Talk
- usesproduction bundler
“switching our production bundler from Metro to Re.Pack”
YouTube Unverified1 source· Talk
- metricKlar app: Android startup reduced from 30 seconds to under 3 seconds on the same low-end device
“we got it down from 30 seconds to under 3 seconds on that same device”
YouTube Unverified1 source· Talk
- feature
Hermes Agent: Register allocator can hit a memory limit for a large global function and fall back to inefficient allocation
“The size of the global function is causing the register allocator to hit a memory limit”
YouTube Unverified1 source· Talk
- featureReact Native: Hermes limit issue fixed in version 0.75
“this is fixed in React Native 0.75”
YouTube Unverified1 source· Talk






