mirror of
https://github.com/hexastack/hexabot
synced 2024-11-23 01:55:15 +00:00
34 lines
917 B
HTML
34 lines
917 B
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<meta charset="UTF-8" />
|
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
<title>Widget Embed</title>
|
|
<script
|
|
crossorigin
|
|
src="https://unpkg.com/react@18/umd/react.production.min.js"
|
|
></script>
|
|
<script
|
|
crossorigin
|
|
src="https://unpkg.com/react-dom@18/umd/react-dom.production.min.js"
|
|
></script>
|
|
<link rel="stylesheet" href="./style.css" />
|
|
<script src="./hexabot-widget.umd.js"></script>
|
|
</head>
|
|
<body>
|
|
<div id="hb-chat-widget"></div>
|
|
<script>
|
|
const el = React.createElement;
|
|
const domContainer = document.getElementById('hb-chat-widget');
|
|
ReactDOM.render(
|
|
el(HexabotWidget, {
|
|
apiUrl: 'http://localhost:4000',
|
|
channel: 'offline',
|
|
token: 'token123',
|
|
}),
|
|
domContainer,
|
|
);
|
|
</script>
|
|
</body>
|
|
</html>
|