From e0693720f0e8bb71265e68e7483eb0ba800ee8c0 Mon Sep 17 00:00:00 2001 From: Kia <1823355+mistakia@users.noreply.github.com> Date: Wed, 25 Jul 2018 21:08:31 -0400 Subject: [PATCH] docs(api): add store closed event --- API.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/API.md b/API.md index 87a4631..6db41f6 100644 --- a/API.md +++ b/API.md @@ -75,6 +75,7 @@ const db = await orbitdb.keyvalue('profile') - [load.progress](#loadprogress) - [ready](#ready) - [write](#write) +- [closed](#closed) ## Public Instance Methods ### orbitdb.create(name, type, [options]) @@ -546,3 +547,9 @@ db.events.on('write', (dbname, hash, entry) => ... ) ``` Emitted after an entry was added locally to the database. *hash* is the IPFS hash of the latest state of the database. *entry* is the added database op. + +#### `closed` +Emitted once the database has finished closing. +```javascript +db.events.on('closed', (dbname) => ... ) +```