Skip to content

Instantly share code, notes, and snippets.

@amonshiz
amonshiz / ConstraintViewController.m
Last active August 29, 2015 14:10
A simple gist demonstrating how one could use Autolayout to dynamically grow a view.
#import "ViewController.h"
@interface ViewController ()
@property (weak, nonatomic) IBOutlet NSLayoutConstraint *bottomConstraint;
@property (weak, nonatomic) IBOutlet UIButton *addButton;
@property (weak, nonatomic) IBOutlet UIView *containerView;
@property (nonatomic, weak) UIView *lastView;
@end