Skip to content

Commit

Permalink
Export mnemonicPhraseToBytes and createBip39KeyFromSeed (#149)
Browse files Browse the repository at this point in the history
* Export `mnemonicPhraseToBytes` and `createBip39KeyFromSeed`

* Run yarn lint:fix

* Update tests for coverage
  • Loading branch information
Mrtenz authored Jul 14, 2023
1 parent 5bf9fc4 commit 2e7aced
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 1 deletion.
7 changes: 7 additions & 0 deletions src/derivers/index.test.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
import { createBip39KeyFromSeed } from '.';

describe('index', () => {
it('has expected exports', () => {
expect(createBip39KeyFromSeed).toBeDefined();
});
});
2 changes: 2 additions & 0 deletions src/derivers/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,5 @@ export const derivers = {
bip39,
slip10,
};

export { createBip39KeyFromSeed } from './bip39';
4 changes: 4 additions & 0 deletions src/index.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,8 @@ import {
secp256k1,
ed25519,
isValidBIP32PathSegment,
createBip39KeyFromSeed,
mnemonicPhraseToBytes,
} from '.';

// This is purely for coverage shenanigans
Expand All @@ -17,5 +19,7 @@ describe('index', () => {
expect(secp256k1).toBeDefined();
expect(ed25519).toBeDefined();
expect(isValidBIP32PathSegment).toBeDefined();
expect(createBip39KeyFromSeed).toBeDefined();
expect(mnemonicPhraseToBytes).toBeDefined();
});
});
3 changes: 2 additions & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,5 @@ export {
} from './BIP44CoinTypeNode';
export * from './constants';
export type { CoinTypeToAddressIndices } from './utils';
export { isValidBIP32PathSegment } from './utils';
export { isValidBIP32PathSegment, mnemonicPhraseToBytes } from './utils';
export { createBip39KeyFromSeed } from './derivers';

0 comments on commit 2e7aced

Please sign in to comment.