Created
December 11, 2023 13:58
-
-
Save david-dacruz/222ddd5ef7c58617ca7871a5194a7616 to your computer and use it in GitHub Desktop.
walletCreate
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { PrivateKey } = dogecore; | |
/*------------- create a new wallet -----------*/ | |
function walletCreate() { | |
// @ts-ignore | |
const privateKey = new PrivateKey(); | |
const privkey = privateKey.toWIF(); | |
const address = privateKey.toAddress().toString(); | |
const json = { privkey, address, utxos: [] }; | |
console.log({ json }); | |
return json; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment