Which gem is the best for dynamic image resizing from an S3 URL?
Hi,
Which gem is the best for dynamic image resizing from an S3 URL? I know i can pre define this, but I have hundreds of people using the product with endless uses cases I'd like them to specify the width in a url parameter, then cache the image for later use.
Note I am using CarrierWave and Fog currently to handle the upload process, perhaps I can leverage one of these gems?
Refile actually provides a Sinatra app that will let you do this. https://github.com/refile/refile#processing
Using something Shrine, I imagine you can build a plugin to do that similarly.
Be awere that you're definitely going to want to cache this to a CDN because you do not want to have to process an image every single request. That's way too much unnecessary work, so you want to do it the first time and then have it cached in the CDN.
Another option would be to generate say 5 different sizes and let the user specify the dimensions, but use CSS to resize the image in the browser and grab the smallest size that fits those dimensions.