$ show godruoyi/gblog
gblog is an open-source personal blog template and live website built on Astro. It statically generates pages from Markdown/MDX content collections, providing a typical blog surface: post listing, categories, timeline, friends page, full-text RSS, sitemap, 404 page, and SEO/OpenGraph metadata. The site integrates Algolia DocSearch, Giscus-based comments, Umami/Google Analytics, and an image optimization pipeline with blur-up placeholders. It also includes a small Cloudflare Pages Functions API backing a "life snapshots" gallery, with uploads stored in R2 and metadata in KV, plus a client-side React timeline component that progressively loads gallery entries from that API with a local fallback. The codebase is a hybrid of polished infrastructure and personal content. The Astro config uses modern integrations (MDX, Tailwind, React, Partytown, compress, sitemap), and several support modules are cleanly isolated — e.g., a Sharp-based blur placeholder generator, a full-content MDX RSS endpoint built on Astro's experimental container, and an idempotent batch image conversion/upload script using OpenDAL. The project is actively maintained by a single author and reflects real production use, but it has no automated test suite, contains a couple of small leftover TODOs (e.g., BackTop button), and couples some configuration values (Algolia API key, analytics IDs) directly into source. Overall, this is a well-structured application template for someone wanting a fully-featured, visually polished Astro blog. It demonstrates solid architecture for a personal project: clear separation of content, components, support utilities, and deployment functions. While it is not a library, several of its support modules and edge-function patterns can be lifted into other Astro or Cloudflare projects with minimal adaptation. The primary value is as a production-grade reference implementation of a static blog with serverless image/gallery extensions.
The LLM identified 4 files worth highlighting for reuse:
Generates a full-content RSS feed for an Astro blog by rendering MDX posts through Astro's experimental container, walking the resulting HTML to absolutize relative links, and sanitizing away script/style elements. This solves the common 'full-text RSS with MDX' plumbing problem and is isolated enough that any Astro content-collection project could copy it with minimal changes.
Builds an inline SVG blur-up placeholder from an image file using Sharp and an SVG feGaussianBlur/feComposite filter chain, returning CSS background styles for LQIP usage. It is self-contained, depends only on Node and Sharp, and can be dropped into almost any web project that needs lightweight, dependency-free image previews.
Batch-converts local blog banner/post images to AVIF (resized to a standard 1500x750 crop), uploads them to an S3/R2 bucket via OpenDAL, checks remote existence to keep runs idempotent, and rewrites Markdown image references to CDN URLs. It demonstrates a clean, reusable asset migration/optimization pipeline pattern with non-obvious use of OpenDAL and Sharp.
A Cloudflare Pages Function that handles multipart image uploads: validates auth token, image type/size/width, stores the original in R2, generates a Cloudflare image-resizing URL with auto-height, and appends gallery metadata to KV. It is a self-contained edge function showing a robust pattern for authenticated image ingestion on Cloudflare's storage primitives.