Using Resolver? Check In!

Just curious where my dependency injection system ended up...

Photo by Maranda Vandergriff on Unsplash
defaultContainer.register(LoginViewModel.self) { r in
return LoginViewModel(service: r.resolve(Authentication.self)!)
}
register { LoginViewModel(service: resolve()) }

--

--

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Michael Long

I write about Apple, Swift, and SwiftUI in particular, and technology in general. I'm also a Lead iOS Engineer at InRhythm, a modern digital consulting firm.