This demo app shows how to build a Chat widget with React and CometChat:
To run the demo first setup CometChat:
- Head to CometChat Pro and create an account
- From the dashboard, create a new app called "React chat widget"
- One created, click Explore
- Go to the API Keys tab and click Create API Key
- Create an API key called "React chat widget key" with Full Access
- Go to the Users tab and click Create User
- Create a user with the name "agent" and the UID "agent"
- Click on the Chat Widget tab in the left navigation pane.
- Create 2 widgets for user and agent
- Replace all the values in
.env.local
file with your credentials - Download the repository or by running git clone