Re: [w3c/IndexedDB] Add a new event `onbeforecommit` on the interface IDBTransaction (#314)

It will be nicer to append the check like this:
```ts
function doDangerousAction1(t) {
   // ....
   t.addEventListener('beforecommit', e => assertDBConsistency(e, t))
}
```

Therefore I can enforce a consistency check before the transaction commit then abort the transaction if it goes into a invalid state.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/IndexedDB/issues/314#issuecomment-567310813

Received on Thursday, 19 December 2019 03:07:47 UTC