Skip to content

Repository files navigation

PostHog React Native SDK Example with Expo

This repository serves as a reference implementation for using the PostHog React Native SDK with Expo. It demonstrates how to:

  • Set up PostHog tracking in a React Native Expo application
  • Configure the PostHog provider
  • Implement session replay
  • Use PostHog surveys
  • Handle theme changes and navigation

Getting Started

  1. Clone this repository
  2. Install dependencies:
    npm install
  3. Start the development server:
    npx expo start

You can also run this app in web mode, which is useful for supporting some use cases:

npx expo start --web

Key Features Demonstrated

  • PostHog initialization and configuration
  • Session replay implementation
  • Survey integration
  • Theme-aware tracking
  • Navigation tracking

Requirements

  • Node.js
  • Expo CLI
  • iOS Simulator or Android Emulator (or physical device)

Learn More

For more information about the PostHog React Native SDK, visit our official documentation.

About

React Native app with Expo showcasing how to use PostHog there

Resources

Code of conduct

Security policy

Stars

7 stars

Watchers

0 watching

Forks

Releases

Packages

Used by

Contributors

Languages