Quick Start
import { B2Metric } from '@b2metric/react-native-sdk'
// Initialize at app startup
await B2Metric.init({
apiKey: 'YOUR_API_KEY',
appIdentifier: 'YOUR_APP_IDENTIFIER',
})
// Track an event
B2Metric.logEvent('button_click', {
properties: { screen: 'home' },
})
Important
Call init() once at app startup before using any other SDK method. Subsequent calls are ignored.