Showing Witness Vote Values

Showing Witness Vote Values

The steem.api.getAccounts allows us to query a list of accounts at the same time. And we can compute each account’s witness vote value (combined of own-vote and proxy-vote).

1
2
3
4
5
6
7
8
9
steem.api.getAccounts(accounts, function(err, result) {
var proxy_votes = result[i].proxied_vsf_votes;
var vests = result[i].vesting_shares.replace(" VESTS", "");
var sum = 0;
for (let x of proxy_votes) {
sum += parseFloat(x);
}
// total vote value --- sum
});

We can add these information in client side, using SteemJs when the page DOM is loaded.

Example tool: https://steemyy.com/proxy/?id=justyy

image.png

Or we can add these in the server API.

Example: Witness Ranking Table, you should see extra column showing how big a witness vote is:

Witness Ranking Table: https://steemyy.com/witness-ranking/

image.png


I hope this helps!

Steem On!~

If you like my work, please consider voting for me, thanks!
https://steemit.com/~witnesses type in justyy and click VOTE



Alternatively, you could proxy to me if you are too lazy to vote!

Also: you can vote me at the tool I made: https://steemyy.com/witness-voting/?witness=justyy

Visit me at: https://steemyy.com


This page is synchronized from the post: ‘Showing Witness Vote Values’

Your browser is out-of-date!

Update your browser to view this website correctly. Update my browser now

×