Skip to content

fix(site): give every page a description for link previews - #445

Merged
16bit-ykiko merged 1 commit into
mainfrom
fix/page-descriptions
Nov 15, 2026
Merged

16bit-ykiko merged 1 commit into
mainfrom
fix/page-descriptions

Conversation

@16bit-ykiko

Copy link
Copy Markdown
Member

After #444 a shared docs.clice.io link previewed as one line: every page without a description of its own (all the synced docs) carried the site's tagline, "Next generation C++ tooling".

  • .vitepress/excerpt.ts: a page without a frontmatter description takes its home hero (text. tagline) or its first paragraph of prose (no heading, list, table, quote, fence, container, HTML or image), markdown off, clipped to ~200 characters (110 for Chinese) at a sentence or a word; a paragraph that leads into a list ends with "…". It feeds <meta name="description"> and og:description.
  • The portal page (en/index.md, zh/index.md, the site's own) gets a description naming the four projects, worded after the latest posts and clice's 1.0 README.
  • og:title: a project home is "clice | clice.io" (its hero name) instead of "clice.io"; the portal is "clice.io", not "clice.io | clice.io".

Checked: all 183 built pages have a description, each different; npm run build passes.

Pages without a description of their own (all the synced docs) all
previewed with the site's tagline, 'Next generation C++ tooling', so a
shared link said nothing about its page. A page now takes its home hero
('text. tagline') or its first paragraph of prose, markdown off, clipped
to about 200 characters (110 in Chinese) at a sentence or a word.

The portal page's description names the four projects; a project home
previews as 'clice | clice.io' rather than 'clice.io', and the portal no
longer as 'clice.io | clice.io'.
@16bit-ykiko
16bit-ykiko merged commit 60adb27 into main Nov 15, 2026
1 check passed
@16bit-ykiko
16bit-ykiko deleted the fix/page-descriptions branch November 15, 2026 13:50
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.

1 participant