aws-lambda-image
aws-lambda-image copied to clipboard
Enhancement - parameter to double the size with @2x
https://cdn.shopify.com/s/files/1/0023/8639/5172/products/[email protected]?v=1569423464
While it's trivial to just manually double the size / dimensions it would be a nice to have to pass in @2x somewhere in the url to upscale this.
/100x100/. -> @2x would upscale to 200x200
This seems to be something configurable with ImageMagick syntax: https://imagemagick.org/script/command-line-processing.php#geometry - you can either upscale or downscale.
I don't understand why you want to upscale your image though - you are not improving the image dimension in any way by upscaling.
technically if the original image is say 1mb - 1000x1000 pixels- and you mostly want 100x100 - but for retina - you want @2x it would be 200x200 - the phone would be downloading a larger (though not largest) resolution.
fyi https://github.com/awslabs/serverless-image-handler