Summary
The small image chore, done in place.
Grabbing a picture and getting it down to a sane size is a two-minute job that usually costs a tab, a downloads folder and an image editor. Here it is two calls against paths you name, and the file lands where the rest of the work is.
What it is
Two local file operations: download an image from a URL to a path you choose, and write an optimized copy of an image already on disk.
What you get
- Download an image from a URL to a named output path, with errors reported rather than swallowed
- Resize by width or height, with the aspect ratio held when you give only one
- JPEG and WebP quality from 1 to 100
- Format conversion on the way out
Requirements
Node.js 16 or higher, and a build — clone, npm install, npm run build — then point your client at build/index.js. No account and no key.
