Scrollview with UITableView

How would one code up this in Interface Builder. I tried creating a scroll view with a Title Label, followed by a UIStackView and then followed by a UITableView, however I don't know how to tell the UIScrollView that its "height" will be dynamic based on the number of rows in the tableview?


https://drive.google.com/file/d/1kpweRDZ3dXXCnvoUjWmxPZbLysMqKu7p/view?usp=sharing

I think you have to compute the new height yourself:

h ttps://stackoverflow.com/questions/40944994/setting-dynamic-height-to-uiscrollview-swift


But the principle of a scroll view is to scroll, not adjust its height, isn't it ?

Scrollview with UITableView
 
 
Q