WhoBuilt

What’s New in Reassure 1.0

Jul 17, 2024· 53 min· 666 views·Watch on YouTube

Speakers

Callstack’s Jakub Bąba hosts R&D engineer Maciej and chief engineer Adam to discuss Reassure 1.0 and practical ways to measure React and React Native performance.

What Reassure measures

Maciej describes Reassure as a performance testing tool for React and React Native, with support for measuring standalone JavaScript functions too. It compares a baseline, usually the main branch, with a proposed change so teams can spot regressions before merging. Real user monitoring provides device-level data, but its results can take two to six weeks to appear across a user base.

Repeatable measurements and the 1.0 changes

Reassure runs measurements repeatedly, compares results on the same machine, and uses statistical analysis to account for variation. The default is ten runs per baseline and current version, with more runs available when measurements are noisy. Version 1.0 made WebAssembly support the default for React Native 0.74 compatibility and changed V8 settings; the team said this could make tests run up to 40% faster.

Detecting extra renders

Reassure can identify redundant renders where a state or context change causes a render with unchanged output. It can also flag an initial render followed immediately by another, such as when a useEffect sets state after mounting. These extra renders may matter most in large views or when handling substantial amounts of data.

Where and how to adopt it

Adam recommends trying Reassure locally first, including on side projects or important JavaScript functions, then expanding to selected project areas if useful. Teams should limit tests to business-critical paths because they take time to write and run, and larger React Native tests may need native-module and network mocks. Always add a scenario and assertions where appropriate: a test can pass while measuring the wrong render if it never checks that the expected content appeared.

Making the case and contributing

The guests frame Reassure as an investment in automated performance checks, especially when existing React Native Testing Library scenarios can be reused. They suggest prioritizing complex views, heavy processing, long-lived user data, and lower-end devices rather than testing everything. The project welcomes help with Bun, Vitest, pnpm, CI integrations, and additional report outputs; results are available in Markdown and JSON.

Takeaways

  • Compare changes against a baseline on the same machine, and repeat runs to reduce the impact of timing noise.
  • Treat Reassure as an early feedback layer alongside real user monitoring, which may take weeks to reflect a release.
  • Start with a small set of performance tests for critical screens or costly functions, then expand based on need.
  • Add scenario checks so a passing measurement confirms the intended UI or code path actually ran.
  • Use existing React Native Testing Library tests and mocks where possible to reduce the cost of adopting performance tests.

Mentioned in this talk

Search inside this talk

What was claimed 22

Related talks