Native Litemetrics client built with Expo Router and React Native.
It connects to your Litemetrics server, lets you add providers, and shows analytics pages optimized for mobile.
- Provider onboarding (server URL + admin secret)
- Analytics overview
- Realtime visitors/events
- Insights (behavioral metrics)
- Campaign attribution
- Retention cohorts
- Events explorer
- Users explorer
- Site management (create/update/delete, conversion events)
- Bun 1.2+
- Expo-compatible iOS/Android setup
- A running Litemetrics server with:
- base URL (for example
https://analytics.yoursite.com) - admin secret
- base URL (for example
cd apps/mobile
bun install
bun run startPlatform-specific commands:
bun run ios
bun run android
bun run webType-check:
bunx tsc --noEmit- Open app
- Add provider (
name,baseUrl,adminSecret) - Select site
- Navigate through tabs: Analytics, Events, Users, Settings
app/(auth)- welcome and provider setupapp/(tabs)/(analytics)- analytics pagesapp/(tabs)/(events)- events list and event detailapp/(tabs)/(users)- users list and user detailapp/(tabs)/(settings)- provider + site managementsrc/api- data hooks and API clientssrc/stores- auth/UI statesrc/components- shared UI components
Primary config is in app.config.ts.
Important fields:
ios.bundleIdentifierandroid.packageschemeversionextra.eas.projectId(required for EAS builds; do not leave as placeholder)
- Never commit real admin secrets, DB credentials, tokens, or private keys.
- Keep environment-specific values outside tracked files.
- Provider secrets are stored with
expo-secure-storeon device.
- Confirm app identity values:
ios.bundleIdentifierandroid.packagescheme
- Bump
versioninapp.config.tsfor each release. - If using EAS:
- Set a real
extra.eas.projectId - Add
eas.jsonrelease profiles - Set iOS/Android build numbers (
buildNumber/versionCode)
- Set a real
bunx tsc --noEmitpasses- Launch and verify core flows on at least one iOS and one Android target
- Verify auth flow: add provider, reconnect after app restart
- Verify analytics pages load for selected site
- Verify pull-to-refresh works on Events, Users, and Settings/Sites
- Verify navigation behavior between analytics sections and back buttons
- Confirm no secrets in tracked files:
git grep -nE \"(SECRET|TOKEN|PASSWORD|PRIVATE KEY|API_KEY)\"
- Keep local
.envfiles ignored and environment-specific
- The root workspace currently does not include
apps/mobile; run commands fromapps/mobile.