Injecting my Botpress bot into a React front end
# 🤝help
l
Hi all, I've been working on this for a while and I'm pretty dang stuck. I've had luck doing this with Flowise. But I can't figure it out here on Botpress. Has anyone had luck doing this with Botpress?
e
Copy code
const Botpress = () => {
  const client = useClient({ clientId });

  return (
    <WebchatProvider
      client={client}
      theme={theme}
      configuration={configuration}
    >
      <style>{style}</style>
      <Container
        style={{
          height: "100vh",
          width: "50%",
          display: "flex",
          justifyContent: "space-between",
        }}
      >
        <Header />
        <MessageList />
        <Composer>
          <ComposerInput />
          <ComposerButton />
        </Composer>
      </Container>
    </WebchatProvider>
  );
};

export default Botpress;
I made this component using the botpress react docs to embed the bot in the front end