Repository navigation
Add Open Graph and Twitter Card social preview metadata - #324
Open
astra-intelligence wants to merge 1 commit into
Open
astra-intelligence wants to merge 1 commit into
astra-intelligence wants to merge 1 commit into
Conversation
The site has had a title and meta description but zero og:/twitter: tags, so every share of any CS231n page renders as a blank link preview on Twitter/X, Slack, Discord, LinkedIn and iMessage. This adds a full Open Graph set (type, site_name, title, description, url, image + image dimensions) and Twitter Card summary_large_image to the shared head.html (covers the homepage and every course-note page via existing Liquid vars), plus a 1200x630 og-image.png brand card generated with Pillow.
This branch has not been deployed
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.
This PR adds Open Graph and Twitter Card social preview metadata to CS231n, so course links stop rendering as blank cards when shared on Twitter/X, Slack, Discord, LinkedIn, or iMessage.
What's included:
_includes/head.html(type, site_name, title, description, url, image + image:type/width/height) — covers the homepage and every course-note page via the existing Liquid variables; per-pageog:url/og:titleresolve automatically.summary_large_image+twitter:site(@cs231n) so shares show the preview card on X.og-image.pngbrand card (course name, topic pills, domain), generated by the included Pillow-onlytools/make-og-image.py(byte-reproducible).The image was generated with my own open OG Image Generator tooling. No tracking, no external requests — purely static meta tags.