pail
pail copied to clipboard
Add sync API
I think the majority of operations are async because of the async Block.encode, however it only really is like that because the hash interface used to be async only. It's now optinally async and we're just using sha256 which can be sync in Nodejs. We could switch to an Await<T> interface that allows async/sync operation depending on the environment. This might speed up mutations in Nodejs.
Blockstore is async so maybe not as easy as you thought.