getTablesJson
The getTablesJson method returns a string serialization of all of the Tables in the Store.
getTablesJson(): stringExamples
This example serializes the contents of a Store.
import {createStore} from 'tinybase';
const store = createStore().setTables({pets: {fido: {species: 'dog'}}});
console.log(store.getTablesJson());
// -> '{"pets":{"fido":{"species":"dog"}}}'
This example serializes the contents of an empty Store.
import {createStore} from 'tinybase';
const store = createStore();
console.log(store.getTablesJson());
// -> '{}'
Since
v3.0.0