I've created a view on the storyboard in one of my view controllers and realized that I'll need to reuse it. So I then created a subclass for UIView to consolidate the code. I've selected the view in the storyboard and changed the class to my custom view class. Now I want to create @IBOutlets for a couple of the components in the view (in this case, 2 text fields). When I try and drag&drop from storyboard to custom view file, the only thing it allows me to create is an @IBAction and @IBOutlet is grayed out.
I tried creating the @IBOutlet manually in code and then drag from the circle to the component on the storyboard. Everything seemed to work (i.e. I see the connection in the little black popup and also the circle next to the variable is filled in. But when I run the app, the 2 fields are nil.
Is there a reason why I can only create actions and not outlets? (I'm kind of new to iOS dev).