Skip to content

Conversation

@codedbychavez
Copy link
Contributor

@codedbychavez codedbychavez commented Jan 12, 2026

Describe the purpose of your pull request

This PR fixes the visible loading delay of the copy page button in which the button appears ~1 second after the page is loaded. This issue was reported to me after some QA checks from rest of the content team.

During research and brainstorming, I found that if the button element can be placed next to the H1 element in the source code, then the need for injecting it after the DOM is built would solve the visible delay.
This was accomplish by swizzling just the DocItem/Content component, so the copy page button can be included next to the page Heading.

Related issues (only if applicable)

n/a

How to test? (only if applicable)

Preview link: https://fix-copy-button-loading.docs-xmy.pages.dev/docs/advanced/caching/

What part of the application was affected by the changes?

  • Every documentation page in the Docs

What should be tested?

Requirement checklist

  • I have validated my changes on a test/local environment.
  • I have tested that the code snippets I added work. (Leave unchecked if there are no new code snippets.)
  • I have added my changes to the V1 and V2 documentations.

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jan 12, 2026

Deploying configcat-docs with  Cloudflare Pages  Cloudflare Pages

Latest commit: 251a876
Status: ✅  Deploy successful!
Preview URL: https://2581213e.docs-xmy.pages.dev
Branch Preview URL: https://fix-copy-button-loading.docs-xmy.pages.dev

View logs

@codedbychavez codedbychavez changed the title Fix copy button loading delay Fix copy page button loading delay Jan 12, 2026
@codedbychavez codedbychavez marked this pull request as ready for review January 12, 2026 18:42
@codedbychavez codedbychavez requested a review from a team as a code owner January 12, 2026 18:42
@codedbychavez codedbychavez changed the title Fix copy page button loading delay Fix the visible loading delay of the copy page button Jan 12, 2026
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.

2 participants