0.3.0
0.3.0 makes many changes from 0.2.0. Where possible, old names and types are available with deprecation attributes; these will soon be removed.
- Updated threading model:
MobiusLoop
is now single-threadedMobiusController
runs a loop on a single background queue.- Fixed several issues around hard-to-avoid assertions in loop teardown.
- New
EffectRouter
andEffectHandler
replaceEffectRouterBuilder
(which is deprecated along with several helpers). - Effects in
First
andNext
are now an array rather than a set. This doesn’t imply an ordering guarantee, but does mean that effects don’t have to beHashable
. - Various things renamed or changed from methods to properties to better conform to Swift API Guidelines and for internal consistency:
Initiator
is nowInitiate
, and is only used withMobiusController
.MobiusLoop.getMostRecentModel()
becomeslatestModel
.MobiusController.getModel()
becomesmodel
.Connectable.InputType
andOutputType
becomeInput
andOutput
;Connection.ValueType
becomesValue
.
Update
is now a struct. This isn’t leveraged by Mobius itself at the moment, but makes it easier to write transformations on updates in a fluent style.- For consistency,
MobiusController
is created through amakeController()
method onMobius.Builder
instead of being initialized with a builder argument. - All methods on
MobiusLogger
now have default do-nothing implementations. ConsoleLogger
has been replaced withSimpleLogger
, which can take a consumer function to use instead ofprint
.NoEffect
andBrokenConnection
are deprecated.MobiusHooks.ErrorHandler
now returnsNever
rather thanVoid
.- Mobius no longer adds a public extension to
NSRecursiveLock
. - There are more documentation comments than there used to be.
- Tooling updated to Swift 5.0 and Xcode 11.0.
- Swift Package Manager is explicitly supported for all Apple platforms; Carthage and CocoaPods are supported for iOS only.