Stage Revert Data
This plugin enables users to temporarily stage data changes before committing to the actual data model
A stageData
property flag inside of the view properties
must be added on the desired view configs.
It also should include a list of acceptable commitTransitions
valid VIEW
name for the data to be committed when the transition occurs, A not included commit transition would trigger the staged data to be cleared. An acceptable transition will commit the data into the data model
. e.g. as per the previous example transitioning to VIEW_2
will trigger the staged data to get committed in the model, since the next
transition property is pointing to it and is listed on the commitTransitions
array parameter, otherwise it would get thrown away.
Example
Simply add the plugin to the config when constructing a player instance.
CocoaPods
Add the subspec to your Podfile
Swift Usage
This plugin takes no parameters, and the configuration comes from content, it can just be added to the plugin array: