Skip to content

Fix Scarf pixel injection causing invalid HTML#86

Merged
nscuro merged 2 commits into
mainfrom
fix-scarf
May 19, 2026
Merged

Fix Scarf pixel injection causing invalid HTML#86
nscuro merged 2 commits into
mainfrom
fix-scarf

Conversation

@nscuro
Copy link
Copy Markdown
Member

@nscuro nscuro commented May 19, 2026

Putting an img tag in the <head> section of HTML documents is invalid and produces bad output in WebKit / Chrome based browsers. Didn't bother Firefox for some reason.

Putting an img tag in the `<head>` section of HTML documents is invalid and produces bad output in WebKit / Chrome based browsers. Didn't bother Firefox for some reason.

Signed-off-by: nscuro <nscuro@protonmail.com>
Copilot AI review requested due to automatic review settings May 19, 2026 12:05
@nscuro nscuro added the defect Something isn't working label May 19, 2026
Copy link
Copy Markdown
Contributor

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

This PR adjusts the MkDocs Material template override to avoid injecting a Scarf tracking pixel <img> into the document <head>, which produces invalid HTML and can render poorly in some browsers.

Changes:

  • Switch template override from the extrahead block to the scripts block so the pixel is emitted in the document body.
  • Keep existing conditional config.extra.scarf_pixel gating.

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

Comment thread overrides/main.html Outdated
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Signed-off-by: Niklas <nscuro@protonmail.com>
@nscuro nscuro merged commit 6d5caca into main May 19, 2026
5 checks passed
@nscuro nscuro deleted the fix-scarf branch May 19, 2026 12:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

defect Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants