Created 6 months ago by @apexJCL
Maybe the feature at all it's not that significative because the format isn't widely supported (requiring polyfills for Safari and other browsers), but it surely helps when you're developing a landing site that requires high quality pictures but with the lowest size possible.
By now, webp files can be uploaded/requested, but previews aren't available at all in tables/thumbnails or similar.
I guess the first step towards this is the how php could do this. And here are a couple of libraries:
Both have nice fallbacks in case some option is no available.
And the second question is how we should serve it?
First could be a explicit call with the thumbnailer (defining extension) or automatic serving by detecting the header. The first option requires the developer to use the picture+source element and the second it's seamless for everyone.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
This is available via Intervention Image:
Encode: $webp = (string) Image::make('public/foo.png')->encode('webp');
This should be high priority for anyone looking for the performance perks of next gen formats (It will also make Google Lighthouse happy.
Maybe work this into the thumbnails endpoints?
Maybe work this into the thumbnails endpoints?
I don't hate that idea! Would be very useful if the thumbnailer could not only change sizes, but also convert to different formats. Would be awesome if you could upload one master huge PNG file, which you can then use on the front-end in both jpg, png, and webp formats (or whatever format you require)
To achieve better clarity/visibility, we are now tracking feature requests within the Feature Request project board.
This issue being closed does not mean it's not being considered.
... NEW PR = #1001 🚀
Whoa, thanks @brocgailit!!!
Most helpful comment
I don't hate that idea! Would be very useful if the thumbnailer could not only change sizes, but also convert to different formats. Would be awesome if you could upload one master huge PNG file, which you can then use on the front-end in both jpg, png, and webp formats (or whatever format you require)