-
Notifications
You must be signed in to change notification settings - Fork 21
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support WebP format #39
Comments
Note that |
@sgomes wouldn't that be the consumer's responsibility, not mshots'? So e.g. when we weren't yet using mShots at signup, we checked for WebP compatibility like so: And loaded webp or jpg depending on support: The example screen has a lot of images (and hopefully has much more in the future) so any performance improvements here are significant help: At the same time, we do something like that in Photon where it returns webp images when supported if I remember correct. |
Possibly, yes. I haven't looked at how the responsibility of what image gets displayed is shared between |
Gotcha! Yeah, I would expect the default to remain jpg and WebP require |
WebP format would give us better quality with smaller filesize: https://developers.google.com/speed/webp
Puppeteer doesn't seem to support WebP out of the box (puppeteer/puppeteer#5348), so it would require capturing first in png and then reformatting to WebP before saving.
Puppeteer API docs for reference https://github.com/puppeteer/puppeteer/blob/d615dd3d2c79f12fad81445dd14a4943141bda04/docs/api.md#pagescreenshotoptions
cc @sgomes @josephscott
The text was updated successfully, but these errors were encountered: