Gruruya / nmostr

Nim library for Nostr
https://gruruya.github.io/nmostr/
GNU Affero General Public License v3.0
10 stars 0 forks source link

Refactor hex objects #5

Closed Gruruya closed 1 year ago

Gruruya commented 1 year ago

Redo EventID, PublicKey, SecretKey, and SchnorrSignature. The objects used in messages (everything but SecretKey) now store the hex alongside the bytes in the object as a StackString.

The previous implementation of keys.nim was a wrapper around a wrapper of nim-secp256k1/abi to workaround jsony init issues with the {.requiresInit.} objects provided. Now the module just imports abi.

Breaking changes, so will push first minor version change since inception.