import { write } from '../src/history.js' const opts = { path: 'example/history.db', name: 'example', clear: true, keys: { test: 'custom common key' } } const event = write(opts) event('something just happened') event({ state: 'on', zone: 5, msg: 'another thing just happened' }) event('history writing again') setTimeout(() => (event('interval')), 10000)