1
0
mirror of https://github.com/bigchaindb/js-bigchaindb-driver.git synced 2024-11-25 11:28:37 +01:00

Added sentence to inform that a seed is not obligatory

This commit is contained in:
michielmulders 2017-09-28 13:33:19 +02:00
parent 25054cc136
commit 49fe2e879e

View File

@ -357,7 +357,7 @@ Recap: Asset Creation & Transfer
.then(() => conn.searchAssets('Bicycle Inc.'))
.then(assets => console.log('Found assets with serial number Bicycle Inc.:', assets))
Seed Functionality Ed25519Keypair
Ed25519Keypair Seed Functionality
---------------------------------
BigchainDB JavaScript driver allows you to create a keypair based on a seed.
@ -375,6 +375,11 @@ As our constructor ``Ed25519Keypair()`` only accepts a seed of 32 bytes, we slic
var keypair = new driver.Ed25519Keypair(bip39.mnemonicToSeed("yourString").slice(0, 32))
You can use the ``Ed25519Keypair()`` constructor as well without seed.
.. code-block:: js
var keypair = new driver.Ed25519Keypair()
Divisible Assets
----------------