finds.dev

francoischalifour/medium-zoom

Lightweight Medium-style image zoom for the web. Zero dependencies, any framework, React component via shadcn.

View on GitHubHomepage ↗

★ 3,940TypeScriptMITupdated Oct 2026

// the take

medium-zoom is a zero-dependency JavaScript library that reproduces Medium's click-to-zoom image interaction, usable with plain HTML/JS or any frontend framework, plus a separately installable React component for shadcn/ui projects. It's for anyone who wants the specific 'click an image, it zooms in place, click or scroll to dismiss' effect without pulling in a full lightbox/gallery library.

Genuinely zero runtime dependencies and framework-agnostic at the core — you attach it to a CSS selector and it works the same whether you're in a Vue, Svelte, or vanilla page. It ships real framework examples (vanilla, React, Vue, Svelte) rather than just a React wrapper, and the shadcn component is a separate, properly packaged option with its own stylesheet and keyboard accessibility instead of a bolted-on afterthought. The API surface is tiny: one `data-zoomable` attribute plus a single init call, with esc-to-close and scroll-to-close handled for you. Release process looks disciplined (release-please, CI checks, CHANGELOG) for something this small.

It's strictly single-image zoom — no next/prev navigation or gallery mode, so anything photo-heavy still needs a real lightbox on top of this. There are now two parallel integration paths — import-and-call the core library, or vendor the shadcn component into your repo via its CLI installer — each with its own API and docs, which adds a decision point that isn't obvious from the README and means the shadcn copy won't get updates through npm. Zoom works by cloning and repositioning the actual image element in the DOM, so very large source images can have a visible decode/paint lag on zoom-in that nothing in the top-level docs addresses. It's effectively a single-maintainer project (francoischalifour), so your dependency on it for image UX across a whole site rides on one person's continued bandwidth.

We read the README, the directory tree and a key source file in October 2026. Nobody pays to be listed. How we judge →

// at a glance

Stars
3,940
Forks
168
Language
TypeScript
License
MIT
Last commit
27 Oct 2026

// nearby

If medium-zoom isn't quite it.

All repos →