pear-hyperdb
v1.1.0
Published
HyperDB model for Pear
Downloads
5,009
Readme
pear-hyperdb
npm install pear-hyperdbUsage
const { spec, Model } = require('pear-hyperdb')
const HyperDB = require('hyperdb')const rocks = HyperDB.rocks('./my-rocks.db', spec)
const model = new Model(rocks)
await model.db.ready()
await model.setDhtNodes([{ host: 'holepunch.to', port: 8080 }])
const nodes = await model.getDhtNodes()
console.log(nodes)
await model.close()Modifying the schema
Edit the Hyperschema definition at build.js, then run:
npm run buildLicense
Apache-2.0
