mirror of
https://github.com/pezkuwichain/pezkuwi-common.git
synced 2026-07-24 02:25:41 +00:00
19 lines
654 B
TypeScript
19 lines
654 B
TypeScript
/**
|
|
* @name mnemonicToLegacySeed
|
|
* @summary Creates a valid Ethereum/Bitcoin-compatible seed from a mnemonic input
|
|
* @example
|
|
* <BR>
|
|
*
|
|
* ```javascript
|
|
* import { mnemonicGenerate, mnemonicToLegacySeed, mnemonicValidate } from '@pezkuwi/util-crypto';
|
|
*
|
|
* const mnemonic = mnemonicGenerate(); // => string
|
|
* const isValidMnemonic = mnemonicValidate(mnemonic); // => boolean
|
|
*
|
|
* if (isValidMnemonic) {
|
|
* console.log(`Seed generated from mnemonic: ${mnemonicToLegacySeed(mnemonic)}`); => u8a
|
|
* }
|
|
* ```
|
|
*/
|
|
export declare function mnemonicToLegacySeed(mnemonic: string, password?: string, onlyJs?: boolean, byteLength?: 32 | 64): Uint8Array;
|