Ionic native crop to force the image to square shape


#1

I am using the ionic3 and using ionic native crop to crop the image. I want all cropped image is a square. But the image in portrait mode, it can crop a rectangular shape, how to control it?


#2

Try Cropper.js

Check this link.Hope this one helps


#3

@arjunramdas123 thanks for your reply. So ionic native crop can’t do this?


#4

Using native ionic crop doesn’t have properties like canvas height or cropped height,it just only targetWidth and targetHeight…Every time it’s just a square shape…so use CropperJS