A runtime service to use live website screenshots on your site.
Image URLs have the formats:
https://v1.screenshot.11ty.dev/:url/
https://v1.screenshot.11ty.dev/:url/:size/
https://v1.screenshot.11ty.dev/:url/:size/:aspectratio/
https://v1.screenshot.11ty.dev/:url/:size/:aspectratio/:zoom/
url
must be URI encoded.- Valid
size
values:small
: 375×___ (default)medium
: 650×___large
: 1024×___aspectratio
of9:16
is not supported (throws an error)
opengraph
: always 1200×630, works withzoom
aspectratio
is ignored (no errors thrown)
- Valid
aspectratio
values:1:1
(default)9:16
- Valid
zoom
values:bigger
(1.4devicePixelRatio
)smaller
(0.71devicePixelRatio
)
If the screenshots aren’t updating at a high enough frequency you can pass in your own cache busting key using an underscore prefix _
after your URL.
This can be any arbitrary string tied to your unique build, here’s an example that uses today’s date:
https://v1.screenshot.11ty.dev/:url/_20210802/
https://v1.screenshot.11ty.dev/:url/:size/_20210802/
https://v1.screenshot.11ty.dev/:url/:size/:aspectratio/_20210802/
https://v1.screenshot.11ty.dev/:url/:size/:aspectratio/:zoom/_20210802/