React Integration
Learn how to integrate OrcaHive chatbot widget in React applications.
5 min read
Updated 2025-01-10
Overview
Integrate OrcaHive chatbot seamlessly into your React applications with our React component wrapper.
Documentation In Progress
This documentation is currently being written. Check back soon for the complete guide!
Quick Example
In the meantime, you can use our JavaScript integration in your React app:
import { useEffect } from 'react';
function App() {
useEffect(() => {
// Load OrcaHive widget
const script = document.createElement('script');
script.src = 'https://cdn.orcahive.io/widget.js';
script.setAttribute('data-bot-id', 'your-bot-id');
document.body.appendChild(script);
return () => {
document.body.removeChild(script);
};
}, []);
return <div>Your App</div>;
}For more details, see our JavaScript Integration guide.