WS 1939 - Expose canonical PodcastEpisode structured data on all podcast episode pages#13766
Open
Louis-Matsika wants to merge 13 commits intolatestfrom
Open
WS 1939 - Expose canonical PodcastEpisode structured data on all podcast episode pages#13766Louis-Matsika wants to merge 13 commits intolatestfrom
Louis-Matsika wants to merge 13 commits intolatestfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Updates podcast episode pages to emit canonical PodcastEpisode JSON-LD (schema.org) behind a new podcastEpisodeLinkedData toggle, and standardises JSON-LD @context to https://schema.org across the app.
Changes:
- Add
PodcastSeries+PodcastEpisodeentities (andmainEntity) for podcast episode pages whenpodcastEpisodeLinkedDatais enabled. - Add
mainEntityIdsupport to the sharedLinkedDatacomponent and switch@contexttohttps://schema.org. - Add the new toggle to toggle configs/docs and update snapshots accordingly.
Reviewed changes
Copilot reviewed 66 out of 67 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| ws-nextjs-app/pages/[service]/onDemandAudio/index.test.tsx | Adds snapshot coverage for podcast episode linked data behind a toggle. |
| ws-nextjs-app/pages/[service]/onDemandAudio/OnDemandAudioLayout.tsx | Emits PodcastEpisode/PodcastSeries linked data for episode routes; wires in toggle + RequestContext. |
| ws-nextjs-app/integration/pages/topicPage/pidgin/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/storyPage/mundo/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/storyPage/mundo/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/storyPage/kyrgyz/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/storyPage/kyrgyz/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/storyPage/hausa/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/storyPage/hausa/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/photoGalleryPage/thai/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/photoGalleryPage/thai/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/photoGalleryPage/mundo/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/photoGalleryPage/mundo/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/onDemandAudioPage/pashtoBrand/snapshots/canonical.test.ts.snap | Snapshot update for @context https change + uploadDate change. |
| ws-nextjs-app/integration/pages/onDemandAudioPage/pashto/snapshots/canonical.test.ts.snap | Snapshot update for @context https change + uploadDate change. |
| ws-nextjs-app/integration/pages/onDemandAudioPage/pashto.expired/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/onDemandAudioPage/indonesia/snapshots/canonical.test.ts.snap | Snapshot update for @context https change + uploadDate change. |
| ws-nextjs-app/integration/pages/onDemandAudioPage/indonesia.expired/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/onDemandAudioPage/gahuza.expired/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/mediaAssetPage/pidgin/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/mediaAssetPage/pidgin/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/mediaAssetPage/persian/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/mediaAssetPage/persian/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/mediaAssetPage/arabicTC2/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/mediaArticlePage/pidgin/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/mediaArticlePage/pidgin/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/live/serbian/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/homePage/serbianLat/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/homePage/serbianCyr/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/homePage/kyrgyz/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/homePage/hindi/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/homePage/arabic/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/scotland/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/scotland/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/persianMediaPlayer/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/persianMediaPlayer/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/persian/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/persian/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/news/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/news/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/hausa/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/hausa/snapshots/amp.test.ts.snap | Snapshot update for @context https change. |
| ws-nextjs-app/integration/pages/articles/gahuza/snapshots/canonical.test.ts.snap | Snapshot update for @context https change. |
| src/integration/pages/podcastPage/portugueseEpisode/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/podcastPage/portugueseBrand/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/onDemandTVPage/pashtoBrand/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/onDemandTVPage/pashto.expired/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/onDemandTVPage/hausa/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/mostReadPage/vietnamese/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/mostReadPage/vietnamese/snapshots/amp.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/mostReadPage/mundo/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/mostReadPage/mundo/snapshots/amp.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/liveRadio/kyrgyz/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/liveRadio/korean/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/integration/pages/liveRadio/gahuza/snapshots/canonical.test.js.snap | Snapshot update for @context https change. |
| src/app/pages/TopicPage/snapshots/index.test.jsx.snap | Snapshot update for @context https change. |
| src/app/pages/HomePage/snapshots/index.test.tsx.snap | Snapshot update for @context https change. |
| src/app/lib/config/toggles/testConfig.js | Adds podcastEpisodeLinkedData toggle (test env defaults). |
| src/app/lib/config/toggles/localConfig.js | Adds podcastEpisodeLinkedData toggle (local env defaults). |
| src/app/lib/config/toggles/liveConfig.js | Adds podcastEpisodeLinkedData toggle (live env defaults). |
| src/app/lib/config/toggles/snapshots/index.test.js.snap | Snapshot update for new toggle in env configs. |
| src/app/lib/config/toggles/README.md | Documents the new toggle. |
| src/app/components/LinkedData/types.ts | Adds mainEntityId prop to LinkedData API. |
| src/app/components/LinkedData/index.tsx | Adds mainEntity output support + switches @context to https://schema.org. |
| src/app/components/LinkedData/index.test.tsx | Adds coverage for PodcastEpisode linked data output. |
| src/app/components/LinkedData/snapshots/index.test.tsx.snap | Snapshot updates for https @context + new podcast episode linked data case. |
ws-nextjs-app/pages/[service]/onDemandAudio/OnDemandAudioLayout.tsx
Outdated
Show resolved
Hide resolved
ws-nextjs-app/pages/[service]/onDemandAudio/OnDemandAudioLayout.tsx
Outdated
Show resolved
Hide resolved
Louis-Matsika
commented
Mar 5, 2026
| <script type="application/ld+json"> | ||
| {serialiseForScript({ | ||
| '@context': 'http://schema.org', | ||
| '@context': 'https://schema.org', |
Contributor
Author
There was a problem hiding this comment.
as mentioned in the description, references to http://www.schema.org have been updated to https://www.schema.org as this aligns with schema.org’s new “preferred form” in their docs
this requires alot of snapshots to be updated tho, interested to see what people think, if this change is worth it
shayneahchoon
approved these changes
Mar 5, 2026
pvaliani
approved these changes
Mar 5, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Resolves JIRA: 1939
Summary
updates the linked data supplied by podcast episode pages to follow the PodcastEpisode schema by schema.org
these changes are put behind a new toggle
podcastEpisodeLinkedDataso we can roll them out service by servicereferences to
http://www.schema.orghave been updated tohttps://www.schema.orgas this aligns with schema.org’s new “preferred form” in their docsupdated many snapshots
Testing
using
https://validator.schema.org/and pasting linked data for any podcast episode page with these changes, e.g.http://localhost:7081/russian/podcasts/p076qqzl/p0mv4g8m?renderer_env=livewill validate that the fields we want are now coming through
Useful Links