Skip to content

chatbot - chatwoot #788

Open
TvisharajiK wants to merge 1 commit intomainfrom
chatwoot
Open

chatbot - chatwoot #788
TvisharajiK wants to merge 1 commit intomainfrom
chatwoot

Conversation

@TvisharajiK
Copy link
Contributor

This pull request adds support for integrating Chatwoot live chat to the documentation site. The main changes include loading the Chatwoot script and initializing it with the appropriate configuration.

Chatwoot integration:

  • Added a new script entry for /docs/scripts/chatwoot.js in the docusaurus.config.js file to ensure the Chatwoot widget is loaded on documentation pages.
  • Created the static/scripts/chatwoot.js script, which loads the Chatwoot SDK and initializes it with the correct website token and base URL.

Copilot AI review requested due to automatic review settings February 12, 2026 13:48
@kiloconnect
Copy link

kiloconnect bot commented Feb 12, 2026

Code Review Summary

Status: No Issues Found | Recommendation: Merge

This PR adds Chatwoot chat widget integration, which is a straightforward addition that follows existing patterns in the codebase.

Overview

  • Adds script reference in docusaurus.config.js following the same pattern as other scripts (feedback.js, clarity.js)
  • Creates new static/scripts/chatwoot.js with standard Chatwoot SDK initialization
Files Reviewed (2 files)
  • docusaurus.config.js - Script reference added
  • static/scripts/chatwoot.js - New Chatwoot widget initialization script

Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a Chatwoot live-chat widget integration to the Docusaurus documentation site by loading a new client-side bootstrap script via the site config.

Changes:

  • Added a new Docusaurus scripts entry to load /docs/scripts/chatwoot.js.
  • Introduced static/scripts/chatwoot.js to load the Chatwoot SDK and initialize it with the site token + base URL.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.

File Description
static/scripts/chatwoot.js Loads Chatwoot SDK and initializes the widget on page load
docusaurus.config.js Registers the new Chatwoot bootstrap script to be included on docs pages

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines +1 to +6
(function(d,t) {
var BASE_URL="https://chatwoot.keploy.io";
var g=d.createElement(t),s=d.getElementsByTagName(t)[0];
g.src=BASE_URL+"/packs/js/sdk.js";
g.async = true;
s.parentNode.insertBefore(g,s);
Copy link

Copilot AI Feb 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This file doesn't follow the repository's Prettier conventions (e.g., spacing, const/let instead of var, and consistent quoting). Since static/scripts/*.js is not ignored by Prettier, please reformat this snippet to match the configured style to avoid formatting churn in future edits.

Copilot uses AI. Check for mistakes.
Comment on lines +8 to +12
window.chatwootSDK.run({
websiteToken: 'DNsHCafpdxqz3dDU1SPggAon',
baseUrl: BASE_URL
})
}
Copy link

Copilot AI Feb 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

window.chatwootSDK.run(...) should be terminated with a semicolon (repo Prettier config has semi: true), and the string quoting should be consistent with the repo setting (singleQuote: false). Please format this block accordingly.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant