← Issues index

1. Article paragraphs not in server HTML — Critical

What: The server sends every plain-text paragraph as an empty container; the text exists only inside the JSON data <script>. Paragraphs appear only after the browser runs JavaScript.

<div id="text-element-with-ad"><div></div></div>

Evidence

Cause: story-templates/story-elements/index.js → CustomStoryElement. To insert ads between paragraphs, the text was split with the browser-only DOMParser and <p> tags counted inside a useEffect (never runs on the server).

Since when (git, PV tpml upstream/master; checked 16 Nov 2026): not since launch. At launch (d0db20fd, 28 Feb 2023) text elements went through Quintype's StoryElement, which renders paragraphs on the server. The client-side split arrived on 8 Oct 2024 (f9d0a0e3, "add new custom story element component to render ad after 4th para": getParagraphsArr regex + useEffect); d45f010f (15 Oct 2024) swapped the regex for DOMParser. So every PV story crawled since ~Oct 2024 is affected, including Jan 2026 (before print-to-web).

Traffic around the change (GA4, Google organic sessions incl. Discover; checks/traffic_funnel/ga4_monthly_organic_pv_2024-2026.json): article-landing sessions Aug 2024 4.38M → Nov 2024 2.79M (−36%) → Jan 2025 3.76M → Jul 2025 4.85M. The fall began in Sep 2024 (before the change) and Nov 2024 had a Google core update, so it can't be attributed to #1 alone; there is no lasting step down in totals because Discover (headline and image) dominates. The cost of #1 is mainly long-tail search that PV articles cannot rank for. Varta Setu, the automatic print-to-web system (syndicated-print template, from late Mar 2026), nearly doubled output (11–13K → ~20K stories/month) with no rise in web clicks to articles (Jan–Mar 546–619K/month vs Apr–Oct 474–586K; checks/traffic_funnel/monthly_articles_web_pv_2026.json).

Fix (built, PV): branch fix/ssr-story-paragraphs, commit bcd5d909 (local, not pushed). Server-safe paragraph splitter + per-story ad plan computed during render. Verified: 143 stories / 633 text blocks identical split and ad positions; local server HTML has 0 empty containers vs 1–8 per page in production; same ad/Taboola positions after JavaScript; hydration keeps all paragraph nodes. DH: confirmed same code in quintype/tpml-dh main (0bc245a1, 23 Oct 2026): story-elements/index.js uses DOMParser in getParagraphsArr (line 134) and the module-level countPara / hasRenderedMidAd1/2 (lines 236–238). The PV fix can be ported.

Status (19 Nov 2026): ✅ DH fix live in production (per user); PV still to ship.

DH production verified (19 Nov 2026; checks/ssr_compare/checklist_www.deccanherald.com_2026-11-19_pre-deploy.md → checklist_www.deccanherald.com_2026-11-19.md, dh_live_sample_2026-11-19.json):

Status (16 Nov 2026, per user): 🚧 tech team is testing the fix on DH first; PV to follow shortly after.

Status (11 Nov 2026): 🚧 in progress with tech. Not yet released; re-test with the steps below once it ships.

Verify after release: view-source / JavaScript-disabled test (QA plan T1); Search Console "View crawled page → HTML".

DH fix verified on training (18 Nov 2026; checks/ssr_compare/checklist_deccanherald-training-web.quintype.io_2026-11-18.md vs checklist_www.deccanherald.com_2026-11-18.md): the same 3 stories fetched as Googlebot, before JavaScript. Training: 29 of 29 body paragraphs in the server HTML (16/16, 8/8, 5/5); live DH: 2 of 29. Nothing else regressed on training: H1, title, canonical, hero image, byline, NewsArticle JSON-LD and AMP link unchanged; HTML 1.30 MB (live 1.29 MB). Training is blocked in robots.txt (Disallow: /) and canonicals point to www, so it can't leak into Google. Also seen on training: og:type is now article (live: website, #34). After release: re-run checklist.py --host www.deccanherald.com, then URL Inspection "View crawled page" on 3 stories, then the body-indexing test (#2) after ~4 weeks.