Michael Long
Oct 12, 2022

--

If you create a Factory with an optional type and if you don't do the registration at some point, then yes, the code probably won't do what's expected.

The flip side is that as long as you're handling the optional correctly (no forced unwraps), your app isn't going to crash as it would with Swinject or Resolver.

--

--

Michael Long
Michael Long

Written by 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.

No responses yet