title: UIImage size depending on UITableViewCell height
body: <p>I have a UITableView whose cells have dynamic height. What I want to do is basically having an image that works as container for each tableview row like in the following picture. Since the content for each row is different, the image should be resized in height to contain the text of the cell. </p>
  
  <p><img src="https://i.stack.imgur.com/l5p4C.png" alt="Image container for cell"> </p>
  
  <p>I am wondering what is the best practice to achieve it.</p>
  
  <p>Thanks in advance</p>