Markdown Converter
Agent skill for markdown-converter
This file provides context for AI agents working with the Socialify codebase.
Sign in to like and favorite skills
This file provides context for AI agents working with the Socialify codebase.
BEFORE making ANY code changes, you MUST read CONTRIBUTING.md to understand:
pnpm verify before committing)Failure to follow CONTRIBUTING.md will result in rejected PRs.
Socialify is an open-source service that generates beautiful social preview images for GitHub repositories. It allows users to create customized images with options for logos, descriptions, badges, fonts, and background patterns.
.nvmrc)socialify/ ├── app/ # Next.js App Router pages and API routes │ ├── [_owner]/ # Dynamic routes for /:owner/:repo │ ├── api/ # API endpoints for image generation │ └── layout.tsx # Root layout with providers ├── src/ │ ├── components/ # React UI components │ ├── contexts/ # React context providers │ ├── hooks/ # Custom React hooks │ └── typings/ # TypeScript type definitions ├── common/ # Shared utilities and business logic │ ├── github/ # GitHub API integration │ ├── icons/ # Language/tech icons for images │ ├── types/ # Shared TypeScript types │ ├── renderCard.ts # Card rendering logic │ ├── renderSVG.tsx # SVG generation with Satori │ └── renderPNG.tsx # PNG conversion with resvg-wasm ├── public/ # Static assets (wasm files copied here) ├── .devcontainer/ # VS Code Dev Container configuration ├── .github/skills/ # AI skills for repo-specific workflows ├── .github/workflows/ # CI/CD workflows (build, test, release, docker) └── .changeset/ # Changeset files for versioning
Before making changes:
Before committing:
pnpm verify (runs lint, tests, and build)pnpm changeset✨ Add feature, 🐛 Fix bug, 📝 Update docs)See CONTRIBUTING.md for full details.
pnpm install # Install dependencies pnpm dev # Start development server pnpm build # Production build pnpm lint # Run Biome linter pnpm lint:fix # Auto-fix lint issues pnpm test:unit # Run Jest unit tests pnpm test:e2e # Run Playwright e2e tests pnpm changeset # Create a changeset for PR pnpm verify # Run all checks (lint, tests, build)
Copy
.env.example to .env and configure:
GITHUB_TOKEN - GitHub PAT with public repo read access (required)PROJECT_URL - Base URL (default: http://localhost:3000)GTM_ID - Google Tag Manager ID (optional)@/ for imports (e.g., @/components/...)/.github/skills/add-icon/ - Add or update supported language, framework, library, tool, or platform icons in Socialify. Use when a request involves adding a new icon/logo, mapping a display name to a Simple Icons entry or a custom icon, and updating the language options list used in the UI./.github/skills/frontend-design/ - Create distinctive, production-grade frontend interfaces with high design quality. Use this skill when building web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics./.github/skills/upgrade-simple-icons/ - Upgrade the simple-icons dependency and preserve icons that are no longer available via custom mappings.pnpm test:unit:update-snapshots / pnpm test:e2e:update-snapshotspnpm changeset)GET /:owner/:repo/image - Returns generated social image (SVG/PNG/JPEG/WebP)GET /api/stats.svg - Returns usage statistics badgeCommon query parameters for image customization:
theme - Light/Dark/Autofont - Font family selectionpattern - Background patternlogo - Custom logo URL (SVG data URI)description - Toggle description visibilitylanguage - Toggle language badgestargazers, forks, issues, pulls - Toggle badgesowner - Toggle owner visibility