●MCP — Rork now lets you add and manage your own MCP servers inside Plugins (11/21)●2.5 ROUTE — From 12/1, apps calling gemini-2.5-flash are routed to 3.5 Flash-Lite and billed at its rates (9 days left)●CHANNEL — Users report Android notification channel reads and writes failing in Expo Go●NEW — New: three clues to check before replying to a stuck-on-splash review●EXPORT — Export your projects before you downgrade or cancel a plan●SONNET 4.5 — Apps that call Sonnet 4.5 through the API should switch before it retires on 11/30●MCP — Rork now lets you add and manage your own MCP servers inside Plugins (11/21)●2.5 ROUTE — From 12/1, apps calling gemini-2.5-flash are routed to 3.5 Flash-Lite and billed at its rates (9 days left)●CHANNEL — Users report Android notification channel reads and writes failing in Expo Go●NEW — New: three clues to check before replying to a stuck-on-splash review●EXPORT — Export your projects before you downgrade or cancel a plan●SONNET 4.5 — Apps that call Sonnet 4.5 through the API should switch before it retires on 11/30
When an Expo UI drop-in swap actually removes a dependency
Expo UI went stable in SDK 56 with drop-in replacements for eight community packages. Swapping one import does not always shrink your dependency list. Here is how to decide which swaps actually pay off, straight from the dependency graph.
I expected to delete one line from package.json. The line stayed.
Expo UI became stable in SDK 56. The pickers, sliders, and sheets that used to come from community packages are now backed by real SwiftUI and Jetpack Compose views, and eight of those packages ship drop-in replacements. The official wording is that most migrations are a one-line import swap.
The wallpaper app I run has a screen that pages through images horizontally. Because it handles both paging and jump-to-page, seeing react-native-pager-view on the replacement list felt like an easy win: swap the import, drop the dependency.
The dependency did not drop. The reason lived somewhere else entirely — in another package that requires it. And it was declared under peerDependencies, which means staring at package.json would never have shown it to me.
Before deciding whether to migrate, I needed a mechanical answer to a smaller question: does anything actually get removed?
The replacement table is not a removal table
These are the eight pairs that shipped in SDK 56. The mapping itself is public and stable. The last column is the platform support listed in the official docs as of November 2026, where the recommended @expo/ui version is ~58.0.28.
Community package
Drop-in replacement
Supported (per docs)
@react-native-community/datetimepicker
@expo/ui/community/datetime-picker
Android / iOS / Expo Go
@react-native-community/slider
@expo/ui/community/slider
Android / iOS / Web / Expo Go
react-native-pager-view
@expo/ui/community/pager-view
Android / iOS
@react-native-picker/picker
@expo/ui/community/picker
Android / iOS / Web / Expo Go
@react-native-segmented-control/segmented-control
@expo/ui/community/segmented-control
Android / iOS / Web / Expo Go
@react-native-masked-view/masked-view
@expo/ui/community/masked-view
Android / iOS
@react-native-menu/menu
@expo/ui/community/menu
Android / iOS / Expo Go
@gorhom/bottom-sheet
@expo/ui/community/bottom-sheet
Android / iOS / Web / Expo Go
All eight import paths appear as ./community/... entries in the exports map of @expo/ui 58.0.28 on npm. To check the version you actually have, node -p "Object.keys(require('@expo/ui/package.json').exports)" lists them.
This table answers one question: does a replacement exist? It says nothing about whether swapping to it shrinks your dependency list. That second question has a different answer in every project.
If your motivation is "I want this screen to look like the OS," the first question is enough. If your motivation is "I want fewer native dependencies so that fewer things break on every SDK bump," you need the second one answered before you estimate the work. Mine was the second.
peerDependencies do not show up in a package.json grep
One direct dependency. One screen using it. It reads as removable.
In reality react-native-tab-view requires it, and the requirement is not written where you are looking:
// react-native-tab-view@4.3.4 package.json (excerpt, latest as of November 2026){ "dependencies": { "use-latest-callback": "^0.2.4" }, "peerDependencies": { "react": ">= 18.2.0", "react-native": "*", "react-native-pager-view": ">= 6.0.0" }}
A peer dependency says "I will not install this, but I assume it is there." If you use React Navigation's material top tabs, react-native-tab-view is in your tree, so react-native-pager-view stays. You could convert every one of your own screens to Expo UI and still remove exactly zero npm packages.
It goes one level further. @react-navigation/material-top-tabs 7.8.1 lists react-native-pager-view: ">= 6.0.0" in its own peerDependencies too, so the requirement reaches you from two directions. Removing either holder alone changes nothing.
That was the trap. Whether a swap removes anything is decided not by the package you are replacing, but by whatever else declares it as a peer.
If you only want to check one package before writing any script, npm already has a reverse lookup:
npm explain react-native-pager-view# lines that start with "peer" are peer requirements
npm explain walks back through why a package is installed, peer edges included. It answers one package at a time, though, which makes it awkward when you want all eight side by side to decide where to start. Hence the script below.
✦
Thank you for reading this far.
Continue Reading
What follows includes implementation code, benchmarks, and practical content we hope you'll find useful. This site runs without ads — server and development costs are supported entirely by members like you. If it's been helpful, we'd be truly grateful for your support.
WHAT YOU'LL LEARN
✦You will be able to tell, with a single command, which of the eight Expo UI replacements actually remove a dependency from your specific project
✦You will catch the dependencies that survive the swap through peerDependencies before you spend an afternoon on the migration
✦If you share components across several apps, you will be able to pick which app and which screen to start with based on the dependency graph rather than a guess
Secure payment via Stripe · Cancel anytime
✦
Unlock This Article
Get full access to the rest of this article. Buy once, read anytime. This site is ad-free — your support goes directly toward keeping it running.
Reverse-resolving peers by hand does not scale. This script walks the installed tree and reports, for each of the eight candidates, who requires it and what would be orphaned if it went away.
Save it as scripts/expo-ui-dropin-audit.mjs and run it from the project root.
#!/usr/bin/env node// Decide whether an Expo UI drop-in swap actually removes a dependency.import { readFileSync, readdirSync, existsSync, statSync } from 'node:fs';import { join } from 'node:path';const REPLACEABLE = { '@react-native-community/datetimepicker': '@expo/ui/community/datetime-picker', '@react-native-community/slider': '@expo/ui/community/slider', 'react-native-pager-view': '@expo/ui/community/pager-view', '@react-native-picker/picker': '@expo/ui/community/picker', '@react-native-segmented-control/segmented-control': '@expo/ui/community/segmented-control', '@react-native-masked-view/masked-view': '@expo/ui/community/masked-view', '@react-native-menu/menu': '@expo/ui/community/menu', '@gorhom/bottom-sheet': '@expo/ui/community/bottom-sheet',};const root = process.argv[2] ?? process.cwd();const readJson = (p) => { try { return JSON.parse(readFileSync(p, 'utf8')); } catch { return null; } };const rootPkg = readJson(join(root, 'package.json'));if (!rootPkg) { console.error(`No package.json at ${root}`); process.exit(1); }const directDeps = { ...(rootPkg.dependencies ?? {}) };// Read every installed package manifest, one level deep, scopes included.function collectInstalled(nmDir) { const out = new Map(); if (!existsSync(nmDir)) return out; for (const entry of readdirSync(nmDir)) { if (entry.startsWith('.')) continue; const full = join(nmDir, entry); if (!statSync(full).isDirectory()) continue; if (entry.startsWith('@')) { for (const sub of readdirSync(full)) { const pkg = readJson(join(full, sub, 'package.json')); if (pkg?.name) out.set(pkg.name, pkg); } } else { const pkg = readJson(join(full, 'package.json')); if (pkg?.name) out.set(pkg.name, pkg); } } return out;}const installed = collectInstalled(join(root, 'node_modules'));// Reverse index: who needs this package, split into runtime and peer.const requiredBy = new Map();const peeredBy = new Map();const push = (map, key, value) => map.set(key, [...(map.get(key) ?? []), value]);for (const [name, pkg] of installed) { for (const dep of Object.keys(pkg.dependencies ?? {})) push(requiredBy, dep, name); for (const dep of Object.keys(pkg.peerDependencies ?? {})) { const meta = pkg.peerDependenciesMeta?.[dep]; if (meta?.optional) continue; // an optional peer is not a reason to keep anything push(peeredBy, dep, name); }}const rows = [];for (const [target, replacement] of Object.entries(REPLACEABLE)) { if (!(target in directDeps) && !installed.has(target)) continue; const runtime = (requiredBy.get(target) ?? []).filter((n) => n !== target); const peers = (peeredBy.get(target) ?? []).filter((n) => n !== target); // Packages that only this target needed, and would be orphaned with it. const orphans = Object.keys(installed.get(target)?.dependencies ?? {}).filter((d) => { const others = (requiredBy.get(d) ?? []).filter((n) => n !== target); return others.length === 0 && !(d in directDeps); }); const blockers = [...new Set([...runtime, ...peers])]; rows.push({ target, replacement, direct: target in directDeps, blockers, removes: blockers.length === 0 ? 1 + orphans.length : 0, orphans, });}if (rows.length === 0) { console.log('None of the replaceable packages are installed.'); process.exit(0); }let net = 0;for (const r of rows) { const head = r.blockers.length === 0 ? 'removable' : 'stays'; console.log(`\n${r.target} -> ${r.replacement}`); console.log(` direct dependency: ${r.direct ? 'yes' : 'no (pulled in by something else)'}`); console.log(` verdict: ${head}`); if (r.blockers.length) console.log(` kept by: ${r.blockers.join(', ')}`); if (r.orphans.length) console.log(` orphaned with it: ${r.orphans.join(', ')}`); console.log(` packages removed: ${r.removes}`); net += r.removes;}console.log(`\nTotal: ${rows.length} of 8 candidates present, ${net} packages actually removed.`);
Three details carry the whole result.
It reads both dependencies and peerDependencies. Reading only the first is exactly how I missed react-native-pager-view.
It skips peers marked optional: true in peerDependenciesMeta. An optional peer works fine when absent, so it is not a reason to keep anything installed. Without that check the script biases hard toward "stays" and stops being useful.
It counts orphans. Removing one package does not always remove one package.
What came out, and the one that survived
Here is the run against a tree containing the five candidates I had on hand, plus react-native-tab-view to represent a project with tabs.
@react-native-community/datetimepicker -> @expo/ui/community/datetime-picker direct dependency: yes verdict: removable packages removed: 1react-native-pager-view -> @expo/ui/community/pager-view direct dependency: yes verdict: stays kept by: react-native-tab-view packages removed: 0@react-native-picker/picker -> @expo/ui/community/picker direct dependency: yes verdict: removable packages removed: 1@react-native-masked-view/masked-view -> @expo/ui/community/masked-view direct dependency: yes verdict: removable packages removed: 1@gorhom/bottom-sheet -> @expo/ui/community/bottom-sheet direct dependency: yes verdict: removable orphaned with it: @gorhom/portal packages removed: 2Total: 5 of 8 candidates present, 5 packages actually removed.
Four of five come out. The one that stays is react-native-pager-view — the exact swap I had assumed would be the easy win.
Note also that @gorhom/bottom-sheet removes two packages by itself, because it brings @gorhom/portal along and nothing else uses it. The biggest payoff sits on the hardest migration in the list. Work through these in order of difficulty and you will do the least valuable ones first.
Orphaned versus shared
This tree also has invariant in it, required by both @gorhom/bottom-sheet and @react-native-community/datetimepicker.
The script did not count it as an orphan, and that is correct. Drop the bottom sheet alone and invariant stays, because datetimepicker still wants it.
That answer is only right for one swap at a time, though. Remove both and invariant goes too. The script deliberately stops short of modeling combinations: enumerating them makes the output unreadable and pulls attention away from the question you actually have, which is what to do first.
If you do want exact counts for a batch removal, take the planned removals as arguments, strip them all from requiredBy up front, and then count orphans. It is a few lines of change. I have left mine as-is, because migrating one package at a time and watching what breaks is faster to debug than migrating four and bisecting afterwards.
Where the script gets it wrong, and how to catch it
I wrote this for the setup I actually have: npm, a single app, no workspaces. In other setups the verdict can drift toward "removable" when it should not. A dependency removed by mistake tends to survive the build and fail at runtime, so it is worth knowing the failure modes up front.
Symptom
Likely cause
How to check
Fix
Marked removable, but after removal the app fails with Unable to resolve module
Declarations in nested node_modules/foo/node_modules/... were never read
Run npm explain <package> and look for requirers the script did not list
Make collectInstalled recursive; until then, cross-check with npm explain
In a pnpm project, nearly everything comes back removable
pnpm keeps transitive packages under node_modules/.pnpm, out of reach of a one-level scan
pnpm why <package>
Treat pnpm why as the source of truth and skip the script
Removable in the app, but a shared package breaks in the monorepo
Another workspace's package.json still needs it
Grep every workspace package.json from the repo root
Run the script per workspace; remove only what is removable in all of them
Marked "stays", and removing the listed holder does not change the verdict
More than one package holds it as a peer (tab-view and material-top-tabs, for example)
Count every name in the "kept by" line
Decide on the whole set of holders, not one at a time
Works in Expo Go, crashes in the development build
The native side has not caught up with a native dependency being added or removed
Open the same screen before and after rebuilding
Rebuild the development build after every removal
The first two rows are weaknesses in my own script. They never came up in my setup, so I left them alone, but they may well come up in yours. What I do now is run npm explain (or pnpm why) once on anything the script calls removable, right before deleting it.
Ask the dependency graph whether you can remove it; ask the screen whether you should replace it. That is the line I drew after this round. Handing the first question to a machine and the second to my own eyes made both decisions faster.
Inside a Host, there is no flexbox
There is a second axis to check, independent of dependency counts.
Expo UI components live inside a Host, and layout inside that boundary is handled by SwiftUI and Compose layout primitives — not Yoga flexbox. That behavior is documented, not a surprise, but it is easy to skim past.
Which means even a genuine one-line import swap moves a layout engine boundary at that spot. If the surrounding tree was built around flex: 1 and justifyContent, the arrangement can shift the moment you swap.
Putting both axes together gives a running order:
Layout boundary unchanged
Layout boundary moves
Dependency drops
Start here
High value — pilot it in one app first
Dependency stays
Only if you want the native look
Defer
@react-native-picker/picker and @react-native-masked-view/masked-view tend to land top-left: the replacement is self-contained. @gorhom/bottom-sheet lands top-right, because it wraps an entire existing layout inside itself.
The two swaps that change behavior: PagerView and BottomSheet
"API-compatible" means the prop names and types line up. The rendering is done by SwiftUI and Jetpack Compose, so behavior does not automatically match. Of the eight, these two had the biggest effect on the screens I looked at. The differences below come from the Platform behavior and Compatibility notes sections of the official docs.
Aspect
react-native-pager-view → PagerView
@gorhom/bottom-sheet → BottomSheet
Web
Not supported; rendering on web throws at runtime
Rendered as an HTML dialog
iOS limits
Pages snap on iOS 17+; onPageScroll and onPageScrollStateChanged fire only on iOS 18+
To stack sheets, nest the second inside the first
What you lose
Vertical paging, keyboardDismissMode, overdrag, overScrollMode, the usePagerView hook
BottomSheetBackdrop, BottomSheetHandle, BottomSheetFooter, BottomSheetFlashList and others
How it presents
HorizontalPager on Android, a paged ScrollView on iOS
A native modal, not an inline sheet at the bottom of the parent
Optional extras
react-native-worklets for animated setPage on iOS
None; gestures and animation belong to the OS
The rule fits in one sentence: PagerView is a candidate if you use neither vertical paging nor web; BottomSheet is a candidate only where you already present it as a modal. A sheet that always peeks from the bottom of the screen (the docs call it a persistent inline peek) is not supported on Android, iOS, or web.
One more point on the package count. @gorhom/bottom-sheet lists react-native-reanimated and react-native-gesture-handler as peers. Those are usually used by navigation or other screens, so they stay when the sheet goes. The script's "2 removed" means the sheet plus portal, not reanimated.
Common misreadings
"It's drop-in, so the old package disappears on its own." Swapping the import leaves both the package.json line and any package that holds it as a peer. Whether it actually goes is a separate check — the script, or npm explain.
"Expo UI runs in Expo Go, so no native rebuild is needed." Only some of the eight are listed as included in Expo Go; PagerView and MaskedView are not. And removing the original package removes a native module, so a development build has to be rebuilt.
"If I put flex on the Host, the children lay out with flex too." The official FAQ says flexbox styles apply to the Host itself, and Yoga is not available inside the native context. Inside, you lay things out with Row and Column on Android, or HStack and VStack on iOS.
Ordering the work when components are shared across apps
I run several related apps that share a common component layer. That structure means the decision does not stay inside one app.
Editing the shared layer applies everywhere at once. Fast, but a change that moves layout boundaries in shared code multiplies the number of screens you have to look at.
So the order I settled on:
Run the script in every app and build a table of "packages removed." Any app showing zero drops out of this round
Where the counts tie, start with the app that ships least often — there is more room to back out
Any swap that touches shared components gets proven in a single app first, then moved into the shared layer
Separately, ask whether the peer holder itself — react-native-tab-view, in my case — could go. If it does, the whole table changes
That fourth item only occurred to me during this audit. It reframes the work: instead of optimizing the migration, you look at the precondition that decides whether the migration is worth anything. I do not have an answer yet. Dropping a navigation library is not a decision you make to save one npm package.
Once the dependency is gone and the import swapped, the next problem is almost always a native mismatch. pager-view and the packages around bottom-sheet carry native code, and deleting a line from package.json does not remove the old module from the development build already on your device.
This is the sequence I run after every removal:
# 1. Remove it, then check for drift from Expo's recommended versionsnpm uninstall @react-native-picker/pickernpx expo install --check# 2. Check overall project healthnpx expo-doctor# 3. Rebuild the development build, then open only the swapped screennpx expo run:ios # or rebuild the development build on EAS
If you are considering these swaps, I would save the script and run it once before opening an editor:
node scripts/expo-ui-dropin-audit.mjs .
If the last line reads 0 packages actually removed, then migrating for dependency reduction does not pay off in this project right now. That is the moment to check whether you have a different reason — wanting the screen to feel native — and to decide on that basis instead.
Had I run this first, I probably would have reordered the work before spending time on the pager-view swap. I only noticed when I reread package.json the night after the swap. The check takes under a second. Thanks for reading, and I hope it saves you the same detour.
Share
Thank You for Reading
Rork Lab is ad-free, supported entirely by members like you. We publish practical guides daily with implementation code, benchmarks, and production-ready patterns. If you've found it useful, we'd love to have you on board.