Smithery Logo
MCPsSkillsDocsPricing
Login
Smithery Logo

Accelerating the Agent Economy

Resources

DocumentationPrivacy PolicySystem Status

Company

PricingAboutBlog

Connect

© 2026 Smithery. All rights reserved.

    secondsky

    image-optimization

    secondsky/image-optimization
    Design
    38
    1 installs

    About

    SKILL.md

    Install

    Install via Skills CLI

    or add to your agent
    • Claude Code
      Claude Code
    • Codex
      Codex
    • OpenClaw
      OpenClaw
    • Cursor
      Cursor
    • Amp
      Amp
    • GitHub Copilot
      GitHub Copilot
    • Gemini CLI
      Gemini CLI
    • Kilo Code
      Kilo Code
    • Junie
      Junie
    • Replit
      Replit
    • Windsurf
      Windsurf
    • Cline
      Cline
    • Continue
      Continue
    • OpenCode
      OpenCode
    • OpenHands
      OpenHands
    • Roo Code
      Roo Code
    • Augment
      Augment
    • Goose
      Goose
    • Trae
      Trae
    • Zencoder
      Zencoder
    • Antigravity
      Antigravity
    ├─
    ├─
    └─

    About

    Optimizes images for web performance using modern formats, responsive techniques, and lazy loading strategies...

    SKILL.md

    Image Optimization

    Optimize images for web performance with modern formats and responsive techniques.

    Format Selection

    Format Best For Compression
    JPEG Photos Lossy, 50-70% reduction
    PNG Icons, transparency Lossless, 10-30%
    WebP Modern browsers 25-35% better than JPEG
    AVIF Next-gen 50% better than JPEG
    SVG Logos, icons Vector, scalable

    Responsive Images

    <picture>
      <source srcset="image.avif" type="image/avif">
      <source srcset="image.webp" type="image/webp">
      <img
        src="image.jpg"
        srcset="image-400.jpg 400w, image-800.jpg 800w, image-1200.jpg 1200w"
        sizes="(max-width: 600px) 100vw, 50vw"
        alt="Description"
        loading="lazy"
        decoding="async"
      >
    </picture>
    

    Lazy Loading

    <!-- Native lazy loading -->
    <img src="image.jpg" loading="lazy" alt="Description">
    
    <!-- With blur placeholder -->
    <img
      src="placeholder-blur.jpg"
      data-src="image.jpg"
      class="lazy"
      alt="Description"
    >
    

    Build Pipeline (Sharp)

    const sharp = require('sharp');
    
    async function optimizeImage(input, output) {
      await sharp(input)
        .resize(1200, null, { withoutEnlargement: true })
        .webp({ quality: 80 })
        .toFile(output);
    }
    

    Performance Targets

    Asset Type Target Size
    Hero image <200KB
    Thumbnail <30KB
    Total images <500KB

    Optimization Checklist

    • Use WebP with JPEG fallback
    • Implement responsive srcset
    • Enable lazy loading for below-fold
    • Compress at quality 70-85
    • Serve from CDN
    • Set proper cache headers
    Recommended Servers
    Parallel Web Search
    Parallel Web Search
    Brave Search
    Brave Search
    Jina AI
    Jina AI
    Repository
    secondsky/claude-skills
    Files