The New Architecture (Fabric renderer + TurboModules + Hermes) is the default
in RN 0.75+ and Expo SDK 52+. Old-arch is being phased out — most third-party libraries now ship
interop shims, but a few still need patches. If a native library throws at install, check its
README for a newArchEnabled flag. This sheet pins
to May 2026; check
reactnative.dev
or docs.expo.dev
for current versions.
Install · runSetup
bash
# Expo (managed) — fastest start, no Xcode/Android Studio needed
npx create-expo-app@latest MyApp --template
cd MyApp
npx expo start # press i (iOS) / a (Android) / w (web)
# Bare React Native (full native access)
npx @react-native-community/cli@latest init MyApp
cd MyApp
npx pod-install ios # macOS only
npm run ios # or npm run android
# Node ≥ 20, watchman recommended on macOS:
brew install watchman
Expo vs bare: Expo’s managed workflow is the default recommendation — OTA updates,
config plugins, no Xcode required for most apps. Drop to bare only when you need a native
module Expo’s prebuilt runtime doesn’t support, or you’re wrapping an existing native app.
Where things liveCommon imports
Core primitives ship in react-native. Navigation, gestures, animation,
storage, and most device APIs are separate packages — install on demand.
import { View, Text, Image, ScrollView } from 'react-native'
Core layout + content primitives.
import { Pressable, TouchableOpacity, Button } from 'react-native'
Tappable wrappers. Preferred Pressable.
import { TextInput, Switch, Slider } from 'react-native'
Form primitives.
import { FlatList, SectionList } from 'react-native'
Virtualized lists.
import { StyleSheet, useWindowDimensions, PixelRatio } from 'react-native'
Style + responsive helpers.
import { Platform, StatusBar, Linking, Alert } from 'react-native'
Platform branching + system APIs.
import { NavigationContainer } from '@react-navigation/native'
Root navigation wrapper.
import { createNativeStackNavigator } from '@react-navigation/native-stack'
Native stack (UIKit / Fragment).
import { createBottomTabNavigator } from '@react-navigation/bottom-tabs'
Tabs.
import { SafeAreaView } from 'react-native-safe-area-context'
Notch / dynamic-island insets.
import AsyncStorage from '@react-native-async-storage/async-storage'
Key-value persistence.
import Animated from 'react-native-reanimated'
UI-thread animations.
import { Gesture, GestureDetector } from 'react-native-gesture-handler'
Pan / pinch / long-press.
import * as ImagePicker from 'expo-image-picker'
Camera roll / capture (Expo).
Building blocksCore components
Layout & content
<View style={...}>
The div. Default flex container.
<Text>hello</Text>
All text must be wrapped. Plain strings outside <Text> throw.
JS-driven stack. Use only if you need custom transitions.
createBottomTabNavigator()
Tab bar.
createDrawerNavigator()
Side drawer.
navigation.navigate('Detail', { id })
Push or focus existing screen.
navigation.push('Detail', { id })
Always pushes a new instance.
navigation.goBack()
Pop.
navigation.replace('Login')
Swap current screen (auth flows).
navigation.setOptions({ title: 'New' })
Update header dynamically.
route.params
Read params passed in.
useNavigation() / useRoute()
Hooks for any nested component.
Expo Router (file-based) is an alternative built on react-navigation:
app/index.tsx, app/[id].tsx.
Same primitives below; the routes are inferred from filesystem.
Stack + params
javascript
// npm i @react-navigation/native @react-navigation/native-stack
// npx expo install react-native-screens react-native-safe-area-context
import { NavigationContainer } from '@react-navigation/native';
import { createNativeStackNavigator } from '@react-navigation/native-stack';
const Stack = createNativeStackNavigator();
function Home({ navigation }) {
return
OTA JS bundle update. Native code requires a rebuild.
Best practiceGood to know
Reach for FlashList before FlatList grows.
Once row content is dynamic-height or images, FlatList’s memory ballooning is the most common
source of jank reports. @shopify/flash-list is a near drop-in.
Animations belong on the UI thread.
Reanimated worklets, or the legacy Animated API with useNativeDriver: true.
JS-driven animation drops to a 5fps slideshow as soon as the JS thread does any real work.
Use Pressable, not TouchableOpacity, in new code.
Same touch handling, but the pressed state hook into style
and built-in hitSlop/pressRetentionOffset replace
a stack of older props.
Common trapsWatch out for
Plain strings outside <Text> throw.<View>hello</View> crashes. All text must be inside
<Text> — including whitespace between siblings.
Default flexDirection is column, not row.
Layouts copied from web land arranged top-to-bottom. Set flexDirection: 'row' explicitly.
Native library installs need a rebuild.
Adding a package that touches native code (camera, MMKV, BLE) requires
npx pod-install + rebuild — or eas build.
A Metro reload is not enough; Expo Go won’t pick it up at all.
React Native lets you build iOS and Android mobile apps using React and JavaScript. The New Architecture (Fabric and TurboModules, default in 0.75+) renders native UI widgets, not a WebView, so performance is close to fully native apps. Expo provides a managed workflow for faster iteration.
What is Expo and is it required for React Native?
Expo is an open-source platform that wraps React Native with pre-built native modules, a managed build service (EAS), and the Expo Go app for instant preview. It is optional — bare React Native works without it — but Expo cuts setup time significantly for most projects.
What is the New Architecture in React Native?
The New Architecture consists of Fabric (a new rendering system), TurboModules (lazy-loaded native modules), and the Hermes JavaScript engine. It is the default in React Native 0.75+ and Expo SDK 52+. It enables synchronous native layout, concurrent React features, and faster startup.
How does navigation work in React Native?
React Navigation (@react-navigation/native) is the standard library for screen navigation. Stack, Tab, and Drawer navigators handle the three most common patterns. In Expo Router, the file-system defines routes — similar to Next.js — which is the recommended default for new Expo projects.
What is the difference between React Native and React?
React is a JavaScript library for web UIs that renders to HTML DOM elements. React Native uses the same component model and hooks but renders to native iOS and Android views (View, Text, Image, Pressable) instead of HTML. Sharing logic between web and mobile is possible via shared hooks and context.