react-native-image-crop-picker
react-native-image-crop-picker copied to clipboard
response.mime returned is dependent on options.multiple
Version
Tell us which versions you are using:
- react-native-image-crop-picker v0.36.1
- react-native v0.63.4
Platform
- iOS
Expected behaviour
The detection of image's MIME type should be consistent, regardless of whether the picker was opened with { multiple: true } or with { multiple: false }
Actual behaviour
MIME type (image.mime) returned for heic images is being returned as image/heic when image picker is being opened using { multiple: true }.
MIME type (response.mime) returned for heic images is being returned as image/jpeg when image picker is being opened using { multiple: false }.
Sidenote
Thanks for this library :)
I think that the MIME type information could be better covered in readme, which lists (image/jpeg, image/png) as possible values of response.mime. On a first glance the list might appear to be a complete one, due to lack of ", ..." ", etc" or other indicator of other possible types. Additionally, readme could include a complete list of returned MIME types as a separate subsection.
The typings file comments mime as Selected image MIME type (image/jpeg, image/png, etc). which better portrays the array of possible values. With image/heic added as a possible type in v0.36.1 and returned as image/jpeg, it would make sense to include that type in response.mime's description, too :)
same issue on me
Same here. Is it solved? How do you deal with it guys? By hand?
Single images are forced to jpg