Tell us which versions you are using:
Tell us to which platform this issue is related
Is it possible to compress the image only when it is above a certain size?
currently not, but I would accept PR with such feature if you have some time
+1
There is always maxSize limit in server side. If there is no such feature, we may use compressImageQuality to compress the original image, but how can we ensure that the compressed image size is always less than maxSize in server side?
Or could we expose a method for user to compress image like below?
ImagePicker.openPicker({
compressImageQuality: 0.8,
multiple: true
}).then(images => {
images.forEach(image => {
if (image.size > MAX_SIZE) {
image = ImagePicker.newApiToCompressImageByUser(image);
}
});
// ...
});
Or could we expose something like compressImageQuality but for size like compressImageMaxSize: 2 (2M)?
@ivpusic this feature is very useful, now it has such feature???
Most helpful comment
+1
There is always maxSize limit in server side. If there is no such feature, we may use
compressImageQualityto compress the original image, but how can we ensure that the compressed image size is always less than maxSize in server side?Or could we expose a method for user to compress image like below?
Or could we expose something like
compressImageQualitybut for size likecompressImageMaxSize: 2(2M)?