-
Notifications
You must be signed in to change notification settings - Fork 39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Polyfill nodejs crypto with noble #360
Conversation
✅ Deploy Preview for cheery-moxie-4f1121 ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
importing seed phrase does not work
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tACK
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
tACK d47cbcb
Tested as many wallet functions as I could: derivation of Legacy and HD, Shield and Transparent Txs, Promo Creation and Redemption, Staking and Unstaking - all is working well and the bundles reduced nicely!
Co-authored-by: JSKitty <mail@jskitty.cat>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
re-tACK 9f8419a
Abstract
Quite a few of our libraries use the
crypto
module, which is only available on nodejs.Prior to this PR we were using the
crypto-browserify
. However, in #47, we decided to use thenoble
library, which is considerably smaller.This also paves the way to remove
bn.js
and our next biggest libraryelliptic
, which is the only remaining library which depends on it in the main bundle (Ledger also depends onbn.js
, but it's in a different bundle).This cuts down the main bundle from 419KB to 386KB (Gzipped)
Testing
Test that the polyfill works as intended.
The affected libraries were:
pivx-promos
,hdkey
,base32