- Breaking: ActivityStoreContext.selectActivityEvents and StreamConfigurator.update now explicitly requires a non-null type. This allows Formula to be compatible with Kotlin 1.8
- Breaking: Remove
Integration
andFragmentContract
- Breaking: Remove
Stream
,StreamBuilder
andStreamFormula
- Breaking: Rewrite internals of formula action handling to enable inline re-evaluation. Lots of changes, can review them in #301
- Breaking: Remove
FragmentFlowState.activeKeys
andFragmentFlowState.visibleKeys
- Move
Renderer
andRenderView
fromformula
core intoformula-android
module - Enable fine-grained control of dispatching via
Plugin.defaultDispatcher
,RuntimeConfig.defaultDispatcher
,Transition.ExecutionType
andEffect.Type
. - Remove
RxStream
type alias. - Replace
implementation
function with a value - Breaking: Removed
FlowFactory
andFlow
- Breaking: Replace
FragmentStoreBuilder
withFeaturesBuilder
- Breaking: Rename
FragmentFlowStore
toFragmentStore
,FragmentState
toFragmentOutput
,FragmentFlowState
toFragmentState
- Breaking: Making
FeatureFactory
into an abstract class and modifying theinitialize
API to useParams
wrapper type
- Breaking: Rename
FragmentBindingBuilder
toFragmentStoreBuilder
- Breaking: Removed old
com.instacart.formula.RxStream
. Note: you should usecom.instacart.formula.rxjava3.RxAction
. - Breaking: Removed
Formula.start()
extension, useFormula.toObservable()
extension instead. - Add
FormulaContext.onEvent
to replaceFormulaContext.callback
andFormulaContext.eventCallback
- Add Kotlin coroutine support! New
formula-coroutines
module to providetoFlow()
extension function andFlowStream
. - Add
Listener
type to consolidate event handling types() -> Unit
and(Event) -> Unit
- Breaking: Rename and move
FormulaContext.UpdateBuilder
intoStreamBuilder
. - Breaking: Restructuring
Transition
type intoTransition<State, Event>
andTransition.Result<State>
- Breaking: Make
Formula
abstract class instead of an interface. - Breaking: Introducing
Snapshot
type and changingevaluate
signature. - Renaming
Stream
toAction
(non-breaking change for now) - Add
action.runAgain()
extension function - Add
action.cancelPrevious(previousAction)
extension function - Add
DelegateAction
abstract class - Add child formula support for
context.key
scopes. - Add support for nested
context.key
calls. - Auto-index duplicate listener keys.
- Breaking: Remove
events(observable) { }
utility function. - Removing
rxjava3
from core module. - Moving
key
function intoIFormula
- Breaking: Remove
state.noEffects()
extension function. Usetransition(state)
instead. - Added
StreamFormula
andObservableFormula
. - Allow nullable formula state.
- Breaking: Removing
FormulaFragment.renderView()
function - Breaking: Replace
FormulaFragment.getFragmentContract()
withgetFragmentKey()
. - Breaking: Removing generic key parameter from
KeyState
. - Breaking: Removing generic parameter from
FormulaFragment
- Added new Feature API with
FeatureFactory
and other related classes. - Update
ActivityStoreContext.isFragmentStarted
andActivityStoreContext.isFragmentResumed
functions. - Breaking: Removed
BackStackStore
andBackStack
. - Breaking: Removed
SharedStateStore
. - Breaking: Replacing
FlowDeclaration
andFlowIntegration
withFlowFactory
. - Added
bind(myFeatureFactory) { component -> component.myFeatureDependency() }
binding method. - Added
bind(myFlowFactory) { component -> component.createMyFlowDependencies() }
binding method. - Rename
KeyState
toFragmentState
and move it toandroid
package. - Move
ActivityStoreContext
intoandroid
package. - Move
ActivityStore
intoandroid
package. - Move
FragmentId
intoandroid
package. - Move
FormulaAppCompatActivity
intoandroid
package. - Move
ActivityResult
intoandroid.events
package. - Move
FragmentKey
intoandroid
package. - Move BaseFormulaFragment into
android
package. - Move
DisposableScope
intoandroid
package. - Move
FormulaFragment
intoandroid
package. - Move
BackCallback
intoandroid
package. - Move
FragmentLifecycleEvent
intoandroid.events
package. - Move
Integration
intoandroid
package. - Move
FragmentLifecycleCallback
intoandroid
package. - Move
FragmentComponent
intoandroid
package. - Move
FragmentContract
intoandroid
package. - Move
FragmentFlowState
intoandroid
package. - Move
FragmentFlowStore
intoandroid
package. - Breaking: Replaced
formula.test(inputObservable)
withformula.test().input()
- Add
TestFormulaObserver.assertNoErrors()
- Added
formula-android-compose
module
- Bugfix: Fix runtime ignoring
Formula.key
for the root formula. - [formula-android] Adding main thread check before notifying fragments.
- Breaking: Crash when duplicate fragment contract is registered.
- Migrated
formula-android
to use coreFormula
interface. - Breaking: Delete
FlowStore
andFlowState
. - Adding
formula-rxjava3
module.
- Breaking: Changing from RxJava 2.x to RxJava 3.x
- Change callback key type from String to Any.
- Removed deprecated
state()
extension - Updated AndroidX appcompat to 1.1.0
- Updated AndroidX fragment-ktx extensions to 1.2.1
- Bugfix: Fix
Stream.onTerminate
causing illegal state exception. - Breaking: In formula-android, replacing lastEntry() with visibleState() in FragmentFlowState.
- Allow down-casting
ActivityStoreContext<MyActivity>
toActivityStoreContext<FragmentActivity>
- Enable global fragment error logging.
- Breaking: Replacing
Renderer
functionrender
withinvoke
. You can now directly callrenderer(value)
. - Breaking: Renaming
RenderView
propertyrenderer
torender
. - Breaking: Replaced
TestFormulaObserver.childInput
functions withTestFormula
. - Breaking:
StatelessFormula
no longer implementsFormula
, but rather implementsIFormula
. - Breaking: Removing
child
builder. - Breaking: Renaming
Evaluation.renderModel
toEvaluation.output
. - Breaking: Moving child
key
intoFormula
andStatelessFormula
interfaces.
- Change child formula key from String to Any.
- Maven central release
- Bugfix: Fix
context.key
exit scope logic.
- Breaking: Replacing
message
API with post transition side-effect block. #115
Before:
transition(state.copy()) {
message(analytics::trackEvent)
}
After:
transition(state.copy()) {
analytics.trackEvent()
}
- Initial release.