TinyBase logoTinyBase

Transaction methods

This is the collection of transaction methods within the Store interface. There are only three transaction methods, finishTransaction, startTransaction, and transaction.

finishTransaction

The finishTransaction method allows you to explicitly finish a transaction that has made multiple mutations to the Store, triggering all calls to the relevant listeners.

startTransaction

The startTransaction method allows you to explicitly start a transaction that will make multiple mutations to the Store, buffering all calls to the relevant listeners until it completes when you call the finishTransaction method.

transaction

The transaction method takes a function that makes multiple mutations to the Store, buffering all calls to the relevant listeners until it completes.