-
Notifications
You must be signed in to change notification settings - Fork 36
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve lifecycle #60
Conversation
self.containerView.translatesAutoresizingMaskIntoConstraints = false | ||
self.view.addSubview(self.containerView) | ||
|
||
// We only activate the top and leading constraints to allow the content to size itself. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
But we also activate bottom and trailing.
} | ||
|
||
private final class HammerViewController: UIViewController { | ||
private let containerView = UIView() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It seems to me, we can just use self.view
and do not create additional layer.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
True, but i prefer to keep this for now for consistency
Simulates view controller lifecycle more accurately