@akhilpulse/session-replay-rn
v1.7.12
Published
React Native SDK for session recording, replay, and remote control
Downloads
5,551
Maintainers
Readme
@akhilpulse/session-replay-rn
React Native SDK for session recording, replay, and remote control.
Installation
npm install @akhilpulse/session-replay-rnQuick Start
import SessionReplay from '@akhilpulse/session-replay-rn';
await SessionReplay.init({
serverUrl: 'https://smartlook.replit.app/api',
user: {
userId: 'user_123',
userName: 'Jane Smith',
email: '[email protected]',
},
});Wrap your root component:
import SessionReplay from '@akhilpulse/session-replay-rn';
export default function App() {
return (
<SessionReplay.GestureCapture>
<YourApp />
</SessionReplay.GestureCapture>
);
}API
SessionReplay.init(config)— Initialize and start recordingSessionReplay.trackScreen(name)— Track screen navigationSessionReplay.trackEvent(name, data)— Log custom eventsSessionReplay.pause()/SessionReplay.resume()— Pause/resume recordingSessionReplay.stop()— End the sessionSessionReplay.startLiveSession()— Enable live streaming + remote controlSessionReplay.onRemoteCommand(handler)— Listen for remote commandsSessionReplay.setScreenshotCapture(fn)— Set screenshot capture function
License
MIT
