Self-sizing Child Views
This project is an example of using the
UIContentContainer protocol to allow a child view controller to tell its parent its preferred content size.
See the following blog post for more details:
See the second example in the folder
DynamicContainer-v2 for an example of how to achieve the same effect without using the preferred content size.