Skip to Content
v0.8.0 · shippedNative iOS / Android / Flutter / Capacitor SDKs, A2A discovery, SOC 2 readiness, residency, BYO storage, BYOK. Read the changelog →
QuickstartReact Native

React Native quickstart

Works for bare React Native CLI apps and Expo apps (managed-with-dev-client or bare). Targets React Native 0.82+ with the New Architecture.

1. Install

# React Native CLI npm install @mushi-mushi/react-native @react-native-async-storage/async-storage cd ios && bundle exec pod install && cd .. # Expo npx expo install @mushi-mushi/react-native @react-native-async-storage/async-storage

To enable shake-to-report, also install expo-sensors. On a bare RN CLI project, wire up Expo modules first (one-time):

# Bare RN CLI only — Expo apps already have this npx install-expo-modules@latest npm install expo-sensors cd ios && bundle exec pod install && cd .. # Expo npx expo install expo-sensors

2. Mount the provider

App.tsx
import { MushiProvider } from '@mushi-mushi/react-native' export default function App() { return ( <MushiProvider projectId="YOUR_PROJECT_ID" apiKey="YOUR_PUBLIC_API_KEY" config={{ widget: { trigger: 'both' }, // 'shake' | 'button' | 'both' | 'manual' capture: { console: true, network: true }, }} > <RootNavigator /> </MushiProvider> ) }

<MushiProvider> mounts the floating bug button automatically (unless you set trigger: 'manual'), opens the bottom-sheet report form on tap or shake, and attaches the last 100 console logs and last 50 network requests to every report.

3. Verify

Run your app on a simulator or a device, tap the bug button, type a description, and submit. The report should appear in the Mushi admin console within a couple of seconds, tagged sdk:react-native@<version>.

If nothing arrives:

  • Confirm apiKey is the public ingest key (mushi_pk_...) — not the Supabase service-role key.
  • Confirm <MushiProvider> is at the root of the component tree, above any NavigationContainer.
  • iOS release builds must use HTTPS for the Mushi endpoint (the default).

Pure-native shells should use the iOS or Android SDKs directly. Capacitor / Ionic apps have their own plugin; a step-by-step Capacitor → React Native migration guide covers porting an existing Capacitor app.

Last updated on