Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Multiple Wallets #172

Open
chrisfenos opened this issue Sep 11, 2018 · 1 comment
Open

Multiple Wallets #172

chrisfenos opened this issue Sep 11, 2018 · 1 comment
Labels
enhancement New feature or request

Comments

@chrisfenos
Copy link
Contributor

chrisfenos commented Sep 11, 2018

Is your feature request related to a problem? Please describe.
There is a clear need to allow user's to create multiple wallets.

Describe the solution you'd like
Allow users to create multiple wallets

Need to track the amount of wallets in the reducer and when the user wants to switch wallets we can just change the derived path.

Every wallet name must map to an index in the masterNode.derivePath

var HDNode = require('ethers').HDNode;
var mnemonic = "12 words";
var masterNode = HDNode.fromMnemonic(mnemonic);
console.log(masterNode);
var wallet1 = masterNode.derivePath("m/44'/60'/0'/0/0");
console.log("wallet 1 - " , wallet1);
var wallet2 = masterNode.derivePath("m/44'/60'/1'/0/0");
console.log("wallet 2 - " , wallet2);

Helpful Resources
https://github.com/bitcoin/bips/blob/master/bip-0032.mediawiki
https://github.com/bitcoin/bips/blob/master/bip-0039.mediawiki
https://docs.ethers.io/ethers.js/html/api-advanced.html#hdnode

@GregTheGreek
Copy link
Member

This is a bit different from having multiple wallets to having multiple instances of an hd node.

If we want to support multiple wallets, we should be supporting both HD nodes and importing of NEW private keys. Will need to put on hold to consider the UI implementation of such.

@GregTheGreek GregTheGreek added the enhancement New feature or request label Sep 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants