API Reference
RecordingView
Native container component and useViewRecorder hook for recording standard React Native views
RecordingView
RecordingView is a native container component. Wrap the content you want to record inside it and link it to a recorder session via the sessionId prop.
Import
import { RecordingView, useViewRecorder } from "react-native-view-recorder";Props
RecordingView accepts all standard View props plus:
| Prop | Type | Required | Description |
|---|---|---|---|
sessionId | string | Yes | Session identifier from useViewRecorder(). Links this view to the recorder. |
All other props (e.g. style, pointerEvents, children) are passed through to the underlying native view.
Example
const recorder = useViewRecorder();
<RecordingView
sessionId={recorder.sessionId}
style={{ width: 640, height: 480 }}
>
<MyAnimatedContent />
</RecordingView>Pair this component with the useViewRecorder hook.