How do I use the documentation for bitcoinjs ?
in "http://bitcoinjs.org", they say: "Documentation: Soon. For now, use the tests as a reference."
with a link to "https://github.com/bitcoinjs/bitcoinjs-lib/tree/master/test"
On this page, go to integration and basic.js, at line 20:
var d = bigi.fromBuffer(hash)
var keyPair = new bitcoin.ECPair(d)
var address = keyPair.getAddress()
First line is OK (replace bitcoin by bitcoinjs), I can print the hash in meteor: console.log(hash)
but what I'm suppose to do with "bigi" which comes from line 4: var bigi = require('bigi')
Also
key = bitcoinjs.ECKey.makeRandom();
works but
keyPair = bitcoinjs.ECPair.makeRandom({ rng: rng })
don't
I don't understand which functions or parameters I can use for bitcoinjs ?
you have to dig in code, and look for functionality which you need.
The current version is 1.5.7 and the npm module from my package also is on v1.5.7 which don't have
ECPair in it. see https://github.com/bitcoinjs/bitcoinjs-lib/issues/408
this is coming soon.
when you want more detailed documented library. maybe the bitcore is better for your need. Also
has very good playground/api-refs/documentation. I am packing right now bitcore last version for the meteor. I publish it
this days.
thank you,
ca333