openvibers/openvibe.news Commits

News: the front page's title says what the site is (#50)

OP OpenVibers committed 30 days ago · 648dbd9af3 · 1 file, +2 −1

The front page's <title> was the bare site name. It now says what the site is ("OpenVibe.News: source-backed news, every claim cited"), so search results and shared links read like a product. The shared layout cuts titles at 60 characters, so this one is short. Other pages keep "<page> · OpenVibe.News".

The full suite passes.

Changes

ddiff --git a/server/render/layout.js b/server/render/layout.js
iindex ba23991..d0e2dbc 100644
---- a/server/render/layout.js
++++ b/server/render/layout.js
@@@ -73,7 +73,8 @@ function renderPage(o) {
site: 'news',
siteName: SITE_NAME,
lang: o.lang,
-- title: o.title ? `${o.title} · ${SITE_NAME}` : SITE_NAME,
++ // The front page's title says what the site is (search results show it); every other page is "<page> · OpenVibe.News".
++ title: o.title ? `${o.title} · ${SITE_NAME}` : o.path === '/' ? `${SITE_NAME}: source-backed news, every claim cited` : SITE_NAME,
description: o.description || 'Source-backed news: every claim cites the reports it rests on.',
canonical: o.canonical,
decision: o.decision,