Closed jmatsushita closed 7 years ago
@jmatsushita thank you for your suggestion.
The reason why I opted for levelup
instead of level
is that I did not want leveldown
to become a dependency of node-quadstore
. However, it shouldn't be hard to support both an instance of level
and the current path
string as the first argument of the QuadStore
constructor. I'll look into this soon.
@jmatsushita I've implemented support for pre-instantiated level-y objects. It's currently living here: https://github.com/jacoscaz/node-quadstore/tree/level (brach level
). If you're able, could you please give it a try? It should work exactly as you suggested bar the fact that some form of valueEncoding
must be passed to the constructor of the level-y object. The default serialiser can be used like so:
const store = new QuadStore(level(DB_PATH, { valueEncoding: QuadStore.valueEncoding }));
@jmatsushita merged into this repo.
We have now released this feature in version 2.1.1. Closing this one, bugs should go into dedicated issues.
Hi there,
Just giving a try to node-quadstore and I wonder if it would make sense to provide a more
level
-ish interface to allow getting a store instance with:Allowing this to work with
level-sublevel
would also follow.Cheers,
Jun