Answers for "how to use keytar electron"

1

how to use keytar electron

const keytar = require('keytar');

keytar.setPassword('KeytarTest', 'AccountName', 'secret');

const secret = keytar.getPassword('KeytarTest', 'AccountName');
secret.then((result) => {
    console.log("result: "+ result); // result will be 'secret'
});
Posted by: Guest on January-11-2020

Code answers related to "Javascript"

Browse Popular Code Answers by Language