I want to compress image size that is selected either from gallery or from camera


Is there any possible solution or plugin to achieve this ?


Do you mean lossy or lossless compression?


@manojdcoder. I have an image of 2-3 MB and I want its size as minimum as possible so that quality of the image should also be good enough.


Try toBase64String which accepts second option parameter quality.


But I don’t want base64 string. I want buffer of that image. I want to upload multiple images at the same time. API load is high with base64 strings.