Dexie.Observable.DatabaseChange

Structure of database change object.

Properties

rev : NumberThe revision of this change
type: NumberType of change. 1=CREATED, 2=UPDATED, 3=DELETED
key : anyPrimary key of changed object
table : StringTable name of where the change took place
obj: ObjectContains the created or updated object. Provided only if type=1 or 2 (CREATED or UPDATED) .
mods: ObjectContains a set of key paths (property names or dotted property names) and values that has been modified in the object. Provided only if type=2 (UPDATED)
oldObj: ObjectContains the object as it was before the change. Provided only if type=2 (UPDATED) or 3 (DELETED).
source : any(Optional) Source of the modification. If the Ā“sourceĀ“ property of the Transaction object was set to a value while performing a database operation, this value will be put in the change object. The Ā“sourceĀ“ property is not an official property of Transaction but is added to all transactions when Dexie.Observable is active. The property can be used to ignore certain changes that origin from self.

See Also

Dexie.Observable.js

Table of Contents