Why Nostr? What is Njump?
2025-02-11 15:50:23
in reply to

Richard Schneeman on Nostr: nprofile1q…cp3s2 But it's hacky because there's no guarantee that the deserializer ...

But it's hacky because there's no guarantee that the deserializer doesn't advance past the document. Also...global state.

Here's an implemented version that works:

https://gist.github.com/schneems/d3b91deabe7c5e29d9d5c568227a0fe6

V2 would be to move that data to not be global but instead be behind some interior mutability like an Arc::Mutex so you can pass something into the Deserializer and retain a reference
Author Public Key
npub1tjf3426t659w7x8yl44z2l948wmslmsp2pnta2gs9tp84r3rpawqfx8266