Conversation
Code Review SummaryStatus: 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
Files Reviewed (2 files)
|
There was a problem hiding this comment.
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
scriptsentry to load/docs/scripts/chatwoot.js. - Introduced
static/scripts/chatwoot.jsto 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.
| (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); |
There was a problem hiding this comment.
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.
| window.chatwootSDK.run({ | ||
| websiteToken: 'DNsHCafpdxqz3dDU1SPggAon', | ||
| baseUrl: BASE_URL | ||
| }) | ||
| } |
There was a problem hiding this comment.
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.
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:
/docs/scripts/chatwoot.jsin thedocusaurus.config.jsfile to ensure the Chatwoot widget is loaded on documentation pages.static/scripts/chatwoot.jsscript, which loads the Chatwoot SDK and initializes it with the correct website token and base URL.