Skip to content

Conversation

@abenso
Copy link
Collaborator

@abenso abenso commented Dec 9, 2025

  • Add cross-platform buffer support for browser environments using buffer/ polyfill
  • Introduce toBuffer() utility function that converts multiple input types (Buffer, Uint8Array, or hex string)
    to Buffer
  • Add new flexible input types: TransactionBlobInput and TransactionMetadataBlobInput
  • Update all signing and metadata methods (sign, signEd25519, signEcdsa, signRaw, getTxMetadata) to accept the
    new flexible input types
  • Add comprehensive unit tests for the toBuffer function
  • Update dependencies

This change improves developer experience by allowing transaction blobs to be passed as hex strings or
Uint8Array in addition to Buffer, making the library easier to use in browser environments where Buffer is not
natively available.

This is a fully backward-compatible change - existing code using Buffer will continue to work without any
modifications. The new input types are additions, not replacement

Close #141

🔗 zboto Link

@chcmedeiros chcmedeiros self-requested a review December 10, 2025 08:35
@abenso abenso merged commit 34f113a into main Dec 10, 2025
5 checks passed
@abenso abenso deleted the feat/cross-platform-support branch December 10, 2025 12:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Reduce Buffer usage or limit its exposure to the end application

3 participants