skip to content

When a third-party library blocks a React Native app's move to the New Architecture, how do you decide whether to replace it, fork it, or port it yourselves?

level: principalimportance: should knowfreq 22%

answer

  1. interop buys time, not a future
  2. how central is the feature?
  3. size of the native surface
  4. who maintains it after you touch it
  5. every release removes more legacy code

basics

~20 s

Weigh the feature's importance, a maintained alternative, the native surface and whether the team can own it: replace when a good alternative exists, fork or port when none does and you can maintain it, and treat interop as borrowed time.

solid answer

~50 s

React Native's docs list the options for a legacy-only library: use an **alternative**, upgrade to a version with **first-class support**, or **port it** yourself to Turbo Native Modules or Fabric Native Components; the 0.76 guidance adds opening an issue with the maintainer. I choose by four questions. **How central is it?** A map or payment wrapper on the booking path justifies more effort than a cosmetic component. **Is there a maintained alternative?** If yes, replacing is usually cheapest over time. **How big is the native surface, and can we own it?** A small module is a reasonable port; a large SDK wrapper is a long-term commitment. **What does waiting cost?** Interop may keep it running, but React Native removes legacy code every release and plans to remove interop eventually. I record the choice with an owner and a revisit trigger.

go deeper

for a junior

Know the basic options when a library does not support the New Architecture: look for an update or an alternative, or ask the maintainer.

for a middle

Explain why a library working through interop still needs a plan, and what a port to Turbo Native Modules or Fabric components involves at a high level.

for a senior

Evaluate each blocker on centrality, alternatives, native surface and team skills, and estimate the recurring cost of carrying a fork across React Native releases.

for a principal

Own the portfolio decision: which features justify native ownership, which get replaced or cut, and how revisit triggers keep interop-only dependencies from becoming permanent risk.

## The situation A library that does not support the New Architecture is no longer a problem you can postpone by staying on the old one: since React Native 0.82 there is no old one. If the library runs through the **interop layers**, you have time. If it does not compile or its key paths silently fail, it blocks the upgrade now. Either way the team needs a decision, and it is a judgement call with no single right answer. ## The options React Native itself lists React Native's docs, for libraries built on the legacy native module and component APIs, suggest: 1. **Use an alternative library** that supports the New Architecture. 2. **Upgrade** to a newer version of the same library with first-class support. 3. **Port it yourselves** to Turbo Native Modules or Fabric Native Components. The 0.76 guidance adds **opening an issue** with the maintainer and, for an unmaintained library, looking for an alternative. A **fork** is the practical form of option 3 when the upstream will not accept or release your port. ## The questions that decide it - **How central is the feature?** In a ride-hailing app, the map, location tracking and payment sheet are on the path to revenue; a decorative animation library is not. Central features justify more investment and less risk. - **Is there a credible alternative?** A maintained library with New Architecture support and equivalent features usually wins. Migration cost is paid once; maintenance of your own copy is paid every release. - **How large is the native surface?** A module with a few methods is a contained port. A wrapper around a large vendor SDK drags in that SDK's upgrades and platform quirks. - **Can the team own native code?** A port or fork means Kotlin, Swift or Objective-C, and possibly C++, reviewed and tested by people who will still be there next year. - **What is the licence?** A fork must be allowed and properly attributed. - **What does waiting cost?** Every release since 0.84 removes more legacy classes, and React Native has said interop will eventually go. Waiting is a choice with a deadline you do not control. ## A decision grid | Situation | Leaning | |---|---| | Maintained alternative with equal features | Replace | | Upstream active, migration in progress | Wait on interop, with a deadline, and help upstream | | Upstream dead, small native surface, team has native skills | Fork and port, or bring the code in-house | | Upstream dead, large native surface, no alternative | Port only if the feature is central; otherwise cut or redesign the feature | | Feature is marginal | Remove the feature and the dependency | ## Costs people forget - **Carrying patches**: a fork must be rebased onto every React Native release, and removals in 0.84 and 0.85 show that legacy-adjacent code keeps breaking. - **Testing**: an in-house port needs device tests on both platforms, not just a successful build. - **Knowledge concentration**: a port owned by one engineer is a new single point of failure. - **Opportunity cost**: weeks spent porting a marginal library are weeks not spent on product work. - **Review burden on sensitive code**: a fork of a payment or location library puts security-relevant native code under your own review process, with no upstream reviewers sharing the load. ## Making the decision stick 1. Write the decision down with the reason, an owner and a **revisit trigger** (for example "when upstream ships New Architecture support" or "before the next React Native upgrade"). 2. Add a check to the upgrade checklist so an interop-only library is re-evaluated each time. 3. Where the team ports, consider offering the port upstream so the ecosystem, not only your app, carries it forward. ## Summary Replace when a good alternative exists, wait on interop only with a deadline and an active upstream, fork or port when the feature is central and the team can own native code, and drop the feature when it is marginal. The deciding factors are business centrality, available alternatives, native surface size, team skills and the fact that legacy support in React Native only shrinks.

  • Is 'it works through interop' a good enough reason to keep a library indefinitely?
    No. It is a good reason not to panic, but React Native has said interop will eventually be removed, and legacy classes disappear every release. Keep the library only with an active upstream migration or a planned replacement, and re-check it before each upgrade.
  • How would you argue for removing a marginal feature instead of porting its library?
    Compare the one-off port plus its ongoing cost (rebasing native code every release, testing on both platforms, one more thing only one engineer understands) with the feature's measured value. If few users touch it, removing the feature frees the upgrade and the team, and it can return later on a supported library.

saying these in an interview costs you the question

  • Interop support means the library never needs to be migrated
  • Forking an unmaintained library removes the need for maintenance
  • Every blocking library should be ported in-house to keep control
  • The decision depends only on engineering effort, not business value
  • Disabling the New Architecture is a valid way to keep a blocking library