Getting Started
Get up and running with the Mite SDK for React Native.
Installation
Install the SDK using your preferred package manager:
npm install @usemite/mite-sdkSetup
1. Initialize Mite
Create a Mite instance and initialize it in your app's entry point:
import AsyncStorage from '@react-native-async-storage/async-storage'
import { Mite, MiteProvider } from '@usemite/mite-sdk'
const mite = new Mite({
apiKey: process.env.EXPO_PUBLIC_MITE_API_KEY,
identityStorage: AsyncStorage,
})
mite.init()
export default function RootLayout() {
return (
<MiteProvider miteInstance={mite}>
{/* Your app */}
</MiteProvider>
)
}2. Configuration Options
interface MiteConfig {
apiKey?: string // Your API key
endpoint?: string // Custom backend endpoint (optional)
timeout?: number // Request timeout in ms (default: 5000)
retries?: number // Max retry attempts for failed requests
anonymousId?: string // Optional override for the generated anonymous user id
identityStorage?: MiteIdentityStorage // AsyncStorage-compatible adapter
identificationOptOut?: boolean // Start in anonymous-only mode
}What's Next?
- Identity Management — Learn how user identification works
- Bug Reports — Submit bug reports with attachments
- Releases — Fetch app releases
- Feature Requests — Manage your feature request board