-
Notifications
You must be signed in to change notification settings - Fork 39
Closed
Labels
Description
User need a way to go back/forward to the history of the system lifecycle. To do so, we need to create a history
component with undo
and redo
APIs to navigate into the history of component state.
Proposed APIs
// get the history component
const history = runtime.require('history')
// start historization
history.start()
// go back in the history
history.from(-1) // set the cursor at the index we want, -1 means to start from the end of the history stack
history.back()
// go forward the in history
history.forward()
// dump the current history
const dump = history.dump()
// load an history and inject the modifications to the current system
history.load(dump)
// stop historization
history.stop()