React Typescript

Set up and integrate Convai's Pixel Streaming component in your React TypeScript app using @convai/experience-embed.

Installation Instructions

To install @convai/experience-embed using your preferred package manager, use one of the following commands:

npm

yarn

pnpm

Quick Start (React Ts)

1. Import the Component


2. Set Up a Ref to Access Methods

3. Use the Component in JSX

expId is your unique experience ID from Convai's dashboard.

4. Interact Using Available Methods

Enable/Disable Camera

Enable/Disable Character Audio

Initialise the Experience

5. Customise the Loading Screen (Optional)

Usage:

Full Example

Last updated

Was this helpful?