nostrmini
v1.2.1
Published
in-memory only nostr relay
Downloads
3
Readme
nostrmini
Very small in-memory nostr relay server that uses a dequeue store for events
Written for tests but could also be used as a base for more complex memory routing, for example.
# run from the cli
yarn install
yarn start:dev
Or use as a lib
Add to project:
yarn add nostrmini
Use in tests with a dynamic port:
import NostrMini from 'nostrmini'
const srv = new NostrMini()
srv.listen(0)
const port = srv.address().port
const url = `ws://127.0.0.1:${port}`
// be sure to close all your connections too
afterAll(()=>{
srv.close()
})