Skip to content

Instantly share code, notes, and snippets.

@epexa
Last active April 25, 2018 11:42
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save epexa/70d2fd6d39f45c3e47d44ff237255b2a to your computer and use it in GitHub Desktop.
Save epexa/70d2fd6d39f45c3e47d44ff237255b2a to your computer and use it in GitHub Desktop.
Example async/await on blockchain Golos
const getAccounts = async(accounts) => {
return await golos.api.getAccounts(accounts);
};
getAccounts(['goloscore'])
.then(response => {
console.log(response);
})
.catch(error => {
console.error(error);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment