title: React-native, how to resize the image based on the original size of image?
body: <p>I have list of images to be displayed, wherein size of the image is unknown, how can I display the image fully without any transparent spaces in top and bottom of the image? (I tried getting image size from getSize method, which is eventually giving lot of spaces in top and bottom) I wanted image to resized and fit in like this, <a href="https://i.stack.imgur.com/XSiyy.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/XSiyy.jpg" alt="I wanted image to resized and fit in like this,"></a></p>
  
  <p>But I'm getting white spaces if I put resize mode to contain, and if I put resize mode to stretch the size of small image is loosing its quality <a href="https://i.stack.imgur.com/zWop4.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/zWop4.jpg" alt="and if I put resize mode to stretch the size of small image is loosing its quality"></a></p>
  
  <p>how can I resize the image so that the white spaces are removed, and fit itself</p>