terkelg/skaler — explained in plain English
Analysis updated 2026-07-17 · repo last pushed 2020-03-15
Shrink large phone photos in the browser before they're uploaded to your server.
Build a profile picture uploader that automatically resizes images to a target size.
Resize scanned documents to a specific width while keeping proportions intact.
Reduce storage costs by compressing user-uploaded images client-side before sending them.
| terkelg/skaler | ruanyf/user-tracking-demos | jimliu/baoyu-design | |
|---|---|---|---|
| Stars | 91 | 91 | 90 |
| Language | JavaScript | JavaScript | JavaScript |
| Last pushed | 2020-03-15 | 2019-04-15 | — |
| Maintenance | Dormant | Dormant | — |
| Setup difficulty | easy | easy | easy |
| Complexity | 1/5 | 2/5 | 2/5 |
| Audience | developer | developer | vibe coder |
Figures from each repo's GitHub metadata at analysis time.
Skaler is a tiny tool that shrinks images on your computer before you upload them to a server. Instead of sending a full-resolution photo to your server, you can use this library to make it smaller first, right in the user's browser. This saves storage space on your server, reduces how much data travels over the internet, and cuts down on the processing load your server has to handle. The way it works is straightforward. You give it an image file (the kind you get when someone picks a photo from their computer using a file input), tell it how you want to resize it, and it gives you back a smaller file. You can scale by percentage (make it half the size), resize to a specific width or height while keeping the image's natural proportions, or stretch it to exact dimensions. Everything happens on the user's device using vanilla JavaScript, no server communication needed for the resizing itself. This is perfect for apps where users upload photos: a social media feed, a profile picture uploader, a document scanning app, or any web form that accepts images. Instead of letting users upload massive 5MB phone photos, you can automatically shrink them to 500KB before sending, making the upload faster and keeping your storage bills manageable. The library is only 329 bytes, incredibly small, and has zero dependencies, so it adds almost no weight to your webpage. The project is intentionally minimal and focused on doing one thing well. It uses only built-in browser features (the Canvas API) and plain JavaScript, which means it works everywhere without needing to install extra packages. The README hints that the author plans to explore even faster approaches in the future using newer browser features, but for now, this strikes a balance between simplicity and performance that works in all modern browsers.
A tiny 329-byte JavaScript library that shrinks images in the browser before upload, using only the built-in Canvas API.
Mainly JavaScript. The stack also includes JavaScript, Canvas API.
Dormant — no commits in 2+ years (last push 2020-03-15).
Open-source and free to use in your own projects, check the repo's license file for exact reuse terms.
Setup difficulty is rated easy, with roughly 5min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
double-check against the repo, no cap.