babylonlabs-io / btc-staking-ts

Other
0 stars 4 forks source link

EccLib initialization #3

Open gbarkhatov opened 1 month ago

gbarkhatov commented 1 month ago
  1. initBTCCurve should be added to Readme.md file
  2. Also, it might make sense to reraise this error on the isValidBitcoinAddress function instead of returning false as it's not that the address is invalid, but the setup is not properly initialized.

We can use getEccLib: https://github.com/bitcoinjs/bitcoinjs-lib/blob/master/src/ecc_lib.js#L30 from bitcoinjs-lib