React Native

Track events, identity, and people in a React Native mobile app.

Track events, identity, and people from a React Native app. The API matches the browser SDK: you call track, identify, and people the same way.

Install

npm install trodo

Initialise

Initialise once at app startup, for example in your root component:

import Trodo from 'trodo';

await Trodo.init({ siteId: 'YOUR_SITE_ID' });

Trodo.track('app_opened');
Trodo.identify('user_123');
Trodo.people.set({ plan: 'pro' });

Browser-only auto-capture (DOM clicks, page views) doesn't apply on native. Track the screens and actions that matter with track, and use Identity and People exactly as on the web.

Next

On this page