Skip to content

Conversation

@mattwbeard
Copy link
Contributor

@mattwbeard mattwbeard commented Dec 22, 2025

Description

Added a check for the script so we don't add duplicates

Type of change

  • Fixes

Note

Avoids duplicate Zendesk script loads by checking existing snippet, removes unused state and development flag in src/theme/DocItem/Layout/useZendesk.js.

  • Docs theme hook (src/theme/DocItem/Layout/useZendesk.js):
    • Prevent duplicate Zendesk snippet injection by checking window.zE and existing #ze-snippet before appending the script.
    • Remove useState/isLoaded logic and DEVELOPMENT guard; simplify effect deps to ZENDESK_KEY only.
    • No return value from hook (was isLoaded).

Written by Cursor Bugbot for commit 751829c. This will update automatically on new commits. Configure here.

@vercel
Copy link

vercel bot commented Dec 22, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Review Updated (UTC)
codat-docs Ready Ready Preview, Comment Dec 22, 2025 0:25am

@github-actions
Copy link

Link check results for preview deployment (https://codat-docs-git-fix-duplicate-script-codat.vercel.app):

[]

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

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

This is the final PR Bugbot will review for you during this billing cycle

Your free Bugbot reviews will reset on January 20

Details

Your team is on the Bugbot Free tier. On this plan, Bugbot will review limited PRs each billing cycle for each member of your team.

To receive Bugbot reviews on all of your PRs, visit the Cursor dashboard to activate Pro and start your 14-day free trial.

@pzaichkina pzaichkina enabled auto-merge December 22, 2025 12:28
@pzaichkina pzaichkina merged commit b38af03 into main Dec 22, 2025
6 of 8 checks passed
@pzaichkina pzaichkina deleted the fix-duplicate-script branch December 22, 2025 12:28
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.

3 participants