Integrate Luciq with Expo
This page covers the recommended way to install and configure the Luciq SDK in your Expo application using the Expo Plugin system.
Overview
Luciq supports modern Expo development. The recommended way to install Luciq is by using our Expo Plugin, which automatically handles native project configuration and automates the sourcemap uploading process for your standard builds.
Recommended Setup: Using the Expo Plugin
This is the simplest and most robust way to integrate Luciq into an Expo project.
Configure the Expo Plugin
Add the @luciq/react-native plugin to the plugins array in your app.json file.
{
"expo": {
"plugins": [
[
"@luciq/react-native",
{
"addScreenRecordingBugReportingPermission": true //check note below
}
]
]
}
}The addScreenRecordingBugReportingPermission is an optional helper that automatically adds the required microphone and photo library permissions on iOS and the foreground service permission on Android for the screen recording feature.
Automatic Sourcemap Uploads
A key benefit of using the Expo Plugin is that it automatically handles sourcemap uploads for all your standard Expo builds (eas build). By adding the plugin to your app.json, it will detect your builds and upload the correct sourcemaps to Luciq with no additional configuration required.
Using Luciq
To start using Luciq, import and initialize the SDK in your app’s main file (e.g. App.js).
import Luciq, { InvocationEvent } from '@luciq/react-native';
Luciq.init({
token: 'APP_TOKEN',
invocationEvents: [InvocationEvent.shake],
});You can find your app token by selecting SDK Integration in the Settings menu from your Luciq dashboard.
Legacy: Using a Custom Development Client
For older managed workflows that do not use the Expo plugin system, you will need to use Expo’s custom development client.
Run the dev client package install:
Modify your package.json scripts to use the --dev-client flag for the start command.
Proceed with the Luciq SDK installation and initialization as described above.
Last updated