How getsentry/sentry-react-native works
Main Components
a. JavaScript Layer
• Core SDK Module
• Integration Modules
• React Native Bridge
• Performance Monitoring
• Error Tracking
• Replay System
b. Native Layers
• iOS (Objective-C/Swift) Implementation
• Android (Java/Kotlin) Implementation
• Platform-specific Error Handlers
• Native Crash Reporting
c. External Components
• Sentry Backend Service
• Source Map Processing
• Symbolication Services
┌─────────────────────────────────────────────────────────┐
• React Native App │
• ┤
• Sentry SDK Core │
• ┬─────────────────┬──────────────────┤
• JS Layer │ Bridge Layer │ Native Layer │
• Error Tracking │ - Native Modules│ - iOS SDK │
• Performance │ - Event Bridge │ - Android SDK │
• Breadcrumbs │ - Method Calls │ - Crash Reporter │
• Session Tracking│ │ - Native Traces │
• ┬───────┴────────┬────────┴────────┬─────────┘
• ▼ ▼ ▼
┌─────────────────────────────────────────────────────────┐
• Sentry Backend │
• ┘
Key Interactions to Highlight
a. Data Flow
• Error capture path from JS to Native
• Performance monitoring data collection
• Event buffering and transmission
• Source map processing flow
b. Integration Points
• React Native bridge communication
• Native crash handling
• Performance monitoring hooks
• Network request monitoring
Implementation Details
Technical details such as:
• Native module registration
• Event buffering system
• Offline storage implementation
• Automatic instrumentation points
• SDK initialization flow
Additional Elements
• Version compatibility notes
• Integration points with Expo
• Hermes support indicators
• RAM bundle handling