How do I load a second view correctly in Swift?
- by slooker
I have a view that I'm trying to load in Swift like this, but it crashes with this error:
'NSInternalInconsistencyException', reason: '-[UIViewController _loadViewFromNibNamed:bundle:] loaded the "DetailView" nib but the view outlet was not set.'
Here is the code I'm trying to use to load it.
Second View Controller
import UIKit
class…