title: How do I make my SwiftUI UIViewRepresentable respect intrinsicContentSize in previews?
body: <p>When I create a view in SwiftUI and render it in an Xcode preview, using <code>PreviewLayout.sizeThatFits</code>, the preview adjusts its size according to its content. When I import a UIKIt view using <code>UIViewRepresentable</code>, it appears with a full device-size frame.</p>
  
  <p>Is there a way to make SwiftUI respect the <code>intrinsicContentSize</code> of <code>UIView</code> subclasses?</p>
  
  <pre><code>struct Label: UIViewRepresentable {
  
      func makeUIView(context: UIViewRepresentableContext&lt;Label&gt;) -&gt; UILabel {
          return UILabel()
      }
  
      func updateUIView(_ uiView: UILabel, context: UIViewRepresentableContext&lt;Label&gt;) {
          uiView.text = "Some text"
      }
  }
  
  #if DEBUG
  struct Label_Previews: PreviewProvider {
      static var previews: some View {
          Group {
              Label().previewLayout(.sizeThatFits)
          }
      }
  }
  #endif
  </code></pre>