Skip to content

Conversation

@theletterf
Copy link
Contributor

@theletterf theletterf commented Oct 24, 2025

Math formulas were duplicated on initial page load due to a race condition between server-side HTML rendering and client-side KaTeX initialization (at least according to Claude).

Added DOMContentLoaded event listener for initial page load while preventing double processing with data attributes.

Test: https://docs-v3-preview.elastic.dev/elastic/docs-builder/pull/2106/syntax/math

@theletterf theletterf self-assigned this Oct 24, 2025
@theletterf theletterf requested a review from a team as a code owner October 24, 2025 06:22
@theletterf theletterf requested a review from Mpdreamz October 24, 2025 06:22
@theletterf theletterf added the bug label Oct 24, 2025
@theletterf theletterf enabled auto-merge (squash) October 24, 2025 06:24
@theletterf theletterf merged commit b66cc43 into main Oct 24, 2025
23 checks passed
@theletterf theletterf deleted the fix-math-dupe-formulas branch October 24, 2025 06:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants