Following along the documentation for Swinject, I'm trying to use storyboard injection. I have the following code, but I'm getting this unresolved identifier issue that defaultContainer is not recognized. Not sure if I'm doing something wrong, or if something is broken. I'm using a fresh Xcode iOS (9) project using Swift 2.2 and this code is in a file name SwinjectStoryboard+Setup.swift. Am I missing something?
import Swinject
extension SwinjectStoryboard {
class func setup() {
defaultContainer.registerForStoryboard(CountdownListViewController.self) { r, c in
c.repository = r.resolve(RealmRepositoryService.self)
}
}
}
Following along the documentation for Swinject, I'm trying to use storyboard injection. I have the following code, but I'm getting this unresolved identifier issue that defaultContainer is not recognized. Not sure if I'm doing something wrong, or if something is broken. I'm using a fresh Xcode iOS (9) project using Swift 2.2 and this code is in a file name SwinjectStoryboard+Setup.swift. Am I missing something?