katch!
a very simple wrapper utility for headless chrome to easily export any webpage as
png
,jpeg
,html
(prerender), you can use it viahttp
orcli
.
Usage
# run katch server in a separate terminal window
$ katch serve --listen=:3000
- a screenshot from google.com?
http://localhost:3000/export?format=png&url=https://google.com
- a screenshot but with a big screen?
- a pdf?
- limit execution time to 5 seconds?
NOTE: you can post JSON payload to the same endpoint with the same name as the above query params.
NOTE: for
cli
usage, please run$ katch help
Download ?
you can go to the releases page and pick the latest version. or you can
$ docker run --rm -it ghcr.io/alash3al/katch katch help
Contribution ?
for sure you can contribute, how?
- clone the repo
- create your fix/feature branch
- create a pull request
nothing else, enjoy!
About
I’m Mohamed Al Ashaal, a software engineer 🙂