React

/ The widget as a React component, for React, Next.js, and anywhere components live.

What it is

@humaner/react wraps the same hosted widget, with React props, SSR-safe loading, and open / close you control in code. Every widget feature, none of the script tag.

Coming soon. The API below is what we are building toward. Treat it as a preview.

Install

Terminal

npm install @humaner/react

Use it

app/page.tsx

import { HumanerChat } from '@humaner/react';

export default function Page() {
  return (
    <HumanerChat
      agentId="ag_demo123"
      position="bottom-right"
    />
  );
}
PropTypeWhat it does
agentIdstringYour public agent ID
position"bottom-right" | "bottom-left"Where the bubble sits
colorstringAccent color
greetingstringOne-off greeting override for this embed
defaultOpenbooleanOpen the panel as soon as it mounts