feat(meta): give the site a real social preview - #61
Merged
Conversation
Solon shipped no og:image, so every link to it rendered as a blank grey rectangle in Telegram, Slack and any DM. Adds the Next file-convention card (1200x630) using the site's own palette from globals.css. Also sets metadataBase, which is load-bearing rather than cosmetic: without it Next resolves the generated image to http://localhost:3000/opengraph-image — a tag that is present, looks configured, and is unfetchable by every scraper. The fallback is the real host, so a missing env var degrades to correct instead of to localhost. Verified by building and rendering: 200, image/png, 1200x630, and the homepage emits og:image=https://solon.orangecat.ch/opengraph-image.
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.
Every link to this site currently shares as a blank grey rectangle — it ships no
og:imageat all.Adds the Next file-convention card (
opengraph-image.tsx, 1200x630 — the 1.91:1 size Slack, Telegram and the OpenGraph scrapers crop to), drawn in this site's own palette fromglobals.css.Also sets
metadataBase, which is the load-bearing half. Without it Next resolves the generated image tohttp://localhost:3000/opengraph-image: a tag that is present, looks configured, and is unfetchable by every scraper. The fallback is the real host, so a missing env var degrades to correct instead of to localhost.Verified end-to-end on a sibling repo before porting: build, render,
200 image/png, 1200x630, andog:imageemitted as the absolute production URL. Localtsc --noEmitclean; CI does the build.Part of a fleet-wide sweep — 10 of 15 sites shared blank, found by FleetCrown Atlas.