Skip to content

Fix HTML entities and lang attribute in government propositions JSON-LD blocks#765

Merged
pethers merged 2 commits intomain-ce4c65f9af6aed48from
copilot/sub-pr-743-again
Mar 3, 2026
Merged

Fix HTML entities and lang attribute in government propositions JSON-LD blocks#765
pethers merged 2 commits intomain-ce4c65f9af6aed48from
copilot/sub-pr-743-again

Conversation

Copy link
Contributor

Copilot AI commented Mar 3, 2026

&amp; in <script type="application/ld+json"> is not HTML-decoded, so structured data was emitting literal &amp; strings to crawlers/validators. Also, lang="no" on the Norwegian article was inconsistent with the existing og:locale="nb_NO" and hreflang="nb" metadata.

Changes

  • JSON-LD entity fix (en, no, nl, fr, es, de): replace &amp; with raw & in alternativeHeadline and description fields
// Before (broken in structured data)
"alternativeHeadline": "Analysis of 20 government propositions on Justice &amp; Environment"

// After
"alternativeHeadline": "Analysis of 20 government propositions on Justice & Environment"
  • Norwegian lang attribute (no.html): lang="no"lang="nb" to align with og:locale="nb_NO" / hreflang="nb" already present in the same file

&amp; in HTML <meta> attribute values is intentionally unchanged — attribute values are HTML-decoded by the browser.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

… propositions articles

Co-authored-by: pethers <1726836+pethers@users.noreply.github.com>
Copilot AI changed the title [WIP] Add government propositions articles for analysis Fix HTML entities and lang attribute in government propositions JSON-LD blocks Mar 3, 2026
@pethers pethers marked this pull request as ready for review March 3, 2026 15:36
@pethers pethers merged commit 164bff2 into main-ce4c65f9af6aed48 Mar 3, 2026
@pethers pethers deleted the copilot/sub-pr-743-again branch March 3, 2026 15:36
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