Skip to content

Bun Commands

Using Bun with React Native (especially via Expo) is becoming popular because Bun is much faster than npm/yarn for installs and scripts.

Below is a practical command reference table for working with React Native + Expo using Bun 👇


🚀 Bun + React Native (Expo) Command Cheat Sheet

Section titled “🚀 Bun + React Native (Expo) Command Cheat Sheet”
PurposeCommand
Create Expo app (recommended)bun create expo
Create Expo app with templatebun create expo myApp -t
Create blank Expo appbun create expo myApp --template blank
Create TypeScript Expo appbun create expo myApp --template blank-typescript
Create Expo app (specific template)bun create expo myApp --template tabs
Initialize existing project with Bunbun init

PurposeCommand
Install dependenciesbun install
Add a packagebun add package-name
Add dev dependencybun add -d package-name
Remove packagebun remove package-name
Upgrade dependenciesbun upgrade
Clean install (fresh lockfile)rm -rf node_modules bun.lockb && bun install

PurposeCommand
Start Expo dev serverbunx expo start
Start with clear cachebunx expo start -c
Run on Androidbunx expo run:android
Run on iOS (Mac only)bunx expo run:ios
Run on webbunx expo start --web

PurposeCommand
Open Android emulatorbunx expo start --android
Open iOS simulatorbunx expo start --ios
Show QR codebunx expo start

PurposeCommand
Run any CLI (npx alternative)bunx <command>
Lint projectbunx eslint .
Format codebunx prettier --write .
Type check (TS)bunx tsc --noEmit

PurposeCommand
Install EAS CLIbun add -g eas-cli
Configure buildbunx eas build:configure
Build Androidbunx eas build -p android
Build iOSbunx eas build -p ios
Submit to storebunx eas submit

PurposeCommand
Install Expo dependencies properlybunx expo install <package>
Upgrade Expo SDKbunx expo upgrade
Doctor (check issues)bunx expo doctor
Prebuild (eject)bunx expo prebuild

PurposeCommand
Run custom scriptbun run <script>
Run dev scriptbun run dev
Run build scriptbun run build

PurposeCommand
Run testsbun test
Run Jest (if configured)bunx jest

  • bunx = npx replacement
  • Expo CLI works seamlessly with Bun
  • Avoid using react-native init with Bun directly → Expo is smoother
  • Bun handles installs much faster than npm/yarn

Terminal window
bun create expo myApp --template blank-typescript
cd myApp
bun install
bunx expo start

  • Native modules may sometimes need fallback to npm/yarn
  • iOS builds still depend on Xcode tooling (Bun doesn’t replace that)
  • Some React Native CLI setups are not fully Bun-native yet