The Wayback Machine - https://web.archive.org/web/20241220030307/https://github.com/aws-samples/embed-genai-chat-into-react
Skip to content

aws-samples/embed-genai-chat-into-react

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Embed GenAI chat into React

The React component is a single file ./src/embed.ts. Simply download this into your project and reference from your component like so.

import Chat from "./embed";

Then instantiate an instance of the Chat component like so.

<Chat
	embedUrl="https://xxxxxxxx.chat.qbusiness.xx-xxxx-x.on.aws/"
	embedWidth={600}          // Optional
	embedHeight={650}         // Optional
	embedOffsetRightPc={5}    // Optional
	headerText="Chat"         // Optional
	headerInfo="Chat with us" // Optional
/>

Dependencies

This component has 2 dependencies 1) React, 2) CloudScape Design Components.

npm install --save react
npm install --save @cloudscape-design/components

Security

See CONTRIBUTING for more information.

License

This library is licensed under the MIT-0 License. See the LICENSE file.

About

No description, website, or topics provided.

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published