Skip to main content
Deno 2 is finally here 🎉️
Learn more

gzip_size v0.3.0

ci

Shows the gzipped size of the given file

CLI usage

You can install the command with the following command

deno install -qf --allow-read https://deno.land/x/gzip_size@v0.3.0/cli.ts
$ gzip_size tiger.svg
347 kiB
$ gzip_size tiger.svg --raw
355041
$ gzip_size tiger.svg --include-original
357 kiB → 347 kiB
$ gzip_size tiger.svg --include-original --decimal
365 kB → 355 kB

See gzip_size -h for more details.

API usage

import { gzipSize } from "https://deno.land/x/gzip_size@v0.3.0/mod.ts";

gzipSize(bytes);
// returns gzipped size of the bytes

License

MIT