Skip to content

Fix/analytics review comments#808

Merged
nehagup merged 3 commits intomainfrom
fix/analytics-review-comments
Mar 27, 2026
Merged

Fix/analytics review comments#808
nehagup merged 3 commits intomainfrom
fix/analytics-review-comments

Conversation

@dhananjay6561
Copy link
Copy Markdown
Contributor

Overview

This PR addresses the review comments raised on #807 by resolving script loading consistency and supply-chain risk concerns flagged for the telemetry script added to docusaurus.config.js.

Problem

The telemetry script entry added in #807 was missing the defer: true attribute, making it inconsistent with all other script entries in the scripts array (feedback.js, clarity.js, apollo-init.js), which all specify both async: true and defer: true. This inconsistency could affect script execution order and page load behavior.

Solution

Added defer: true to the telemetry script configuration to align with the existing script loading pattern across the Docusaurus config.

Regarding the SRI (integrity + crossorigin) suggestion — since telemetry.keploy.io is an owned domain and not a true third-party source, the supply-chain risk is minimal. Adding SRI would require manually updating the hash on every SDK update, introducing maintenance overhead and risk of silently breaking analytics on the docs site. This has been consciously deferred.

Files Changed

  • docusaurus.config.js — Added defer: true to the telemetry.keploy.io/sessions/sdk.js script entry.

slayerjain and others added 2 commits March 26, 2026 18:32
Add updated analytics script to improve site usage tracking.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings March 27, 2026 10:19
@kilo-code-bot
Copy link
Copy Markdown

kilo-code-bot bot commented Mar 27, 2026

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Overview

The PR adds a telemetry script configuration to docusaurus.config.js. The implementation:

  • Follows the existing pattern for script entries (both async: true and defer: true)
  • Uses proper syntax for data attributes ("data-endpoint", "data-source")
  • Is consistent with the project's script loading conventions

The configuration is straightforward and correctly structured.

Files Reviewed (1 file)
  • docusaurus.config.js - 0 issues

Reviewed by claude-4.5-opus-20251124 · 60,910 tokens

Copy link
Copy Markdown

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

Aligns the newly added telemetry script configuration with the existing Docusaurus scripts loading pattern to ensure consistent script execution behavior across the docs site.

Changes:

  • Adds defer: true to the https://telemetry.keploy.io/sessions/sdk.js script entry to match other scripts in docusaurus.config.js.

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

Signed-off-by: Dhananjay Aggarwal <133662894+dhananjay6561@users.noreply.github.com>
@nehagup nehagup merged commit 3eb87f7 into main Mar 27, 2026
4 of 7 checks passed
@nehagup nehagup deleted the fix/analytics-review-comments branch March 27, 2026 12:01
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.

4 participants