This is a little code blog, built with React Router 7 and deployed on Cloudflare Workers. I wanted a fast, flexible, themable setup where I could write in MDX and include live, editable code examples in the posts.
- 🚀 React Router 7 with server-side rendering
- ⚡ Cloudflare Workers - everything runs on the edge
- 🎨 AI-generated visuals via Replicate with user-controlled variations per post
- 🍪 Cookie-based routing for clean URLs between index and posts
- 💻 Live code blocks powered by Sandpack
- 🤓 WASM-powered syntax highlighting with Shiki and OG image generation with Satori
- 📝 MDX content with full React component support
- 🖼️ Dynamic social images generated on-the-fly
- 🌓 Dark and light themes that respect system preferences
- 📡 RSS feed for your favorite feed reader
Built with React Router 7 and deployed on Cloudflare Workers.
Content is written in MDX. Code blocks are syntax-highlighted on the server using Shiki with Catppuccin themes. Interactive code blocks use Sandpack to provide a full in-browser editing experience with live preview. Open Graph images are generated dynamically using Satori, which renders React components to SVG.
Prerequisites:
- Node.js 18 or later
- npm
Install dependencies:
npm installStart the development server:
npm run devYour application will be available at http://localhost:5173.
Run tests:
npm testBuild for production:
npm run buildDeploy to Cloudflare Workers:
npm run deployGenerate types for Cloudflare bindings:
npm run typegen