title: Creating a UIScrollView subclass in code, where do I add a subviews to it?
body: <p>Every time I create my <code>UIScrollView</code> subclass I add a <code>UIImageView</code> to it. I get the image for the <code>UIImageView</code> from the scroll view's <code>init</code> method where I pass a <code>UIImage</code>.</p>
  
  <p>But where do I add this subview? Normally I would do it in <code>awakeFromNib</code> but this is created programmatically. And it's bad practice to mess with the view hierarchy in the <code>init</code> methods.</p>
  
  <p>Where should I do it?</p>