Here is my new Nostr relay library: https://doc.deno.land/https://gitlab.com/soapbox-pub/nostr-machina/-/raw/main/mod.ts
https://gitlab.com/soapbox-pub/nostr-machina
It's still experimental and doesn't support a pool yet. But it's comprised of a bunch of useful utilities that makes working with WebSockets and Nostr easier.
https://gitlab.com/soapbox-pub/nostr-machina
It's still experimental and doesn't support a pool yet. But it's comprised of a bunch of useful utilities that makes working with WebSockets and Nostr easier.
Async open, async close. Messages stream. Things that should just be in the WebSocket default.
Also, socket auto-reconnect with exponential backoff, as a pure function: https://gitlab.com/soapbox-pub/nostr-machina/-/blob/main/src/reanimate.ts
Async open, async close. Messages stream. Things that should just be in the WebSocket default.