This is an Expo project demonstrating the features of the expo-superwall SDK. It is created with create-expo-app.
-
Install dependencies
Use your preferred package manager:
npm install # or yarn install # or bun install
-
Configure API Keys
Before running the app, you need to add your Superwall API keys.
- Open
app/index.tsx. - Replace
"YOUR_SUPERWALL_API_KEY"with your actual iOS Superwall API key. - If you are testing on Android, add your Android API key as well.
// Inside app/index.tsx export default function App() { return ( <SuperwallProvider apiKeys={{ ios: "YOUR_SUPERWALL_API_KEY" /* android: "YOUR_ANDROID_API_KEY" */ }}> {/* ... app content ... */} </SuperwallProvider> ); }
- Open
-
Start the app
npx expo start # or yarn expo start # or bun expo start
In the output, you'll find options to open the app in a development build, Android emulator, or iOS simulator. Expo Go can also be used, but development builds are recommended for full native module compatibility.
This project uses file-based routing via Expo Router.
app/index.tsx: InitializesSuperwallProviderand shows basic loading states.app/new.tsx: Demonstrates the new Hooks-based SDK (useUser,usePlacement).app/compat.tsx: Demonstrates the compatibility layer SDK (legacySuperwall.sharedusage).
You can start developing by editing these files or adding new routes within the app directory.
To learn more about developing your project with Expo, look at the following resources:
- Expo documentation: Learn fundamentals, or go into advanced topics with our guides.
- Learn Expo tutorial: Follow a step-by-step tutorial where you'll create a project that runs on Android, iOS, and the web.
- Expo Router Documentation
Join our community of developers creating universal apps.
- Expo on GitHub: View our open source platform and contribute.
- Superwall Discord Community: Chat with Superwall users and ask questions.
- Expo Discord community: Chat with Expo users and ask questions.