Created
January 10, 2017 21:40
-
-
Save lukephills/26787a3a221f2b8917546df140939e82 to your computer and use it in GitHub Desktop.
Function to get current duolingo tree progress
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
function getDuolingoTreeProgress() { | |
var s = $('.skill-icon').length, | |
g = $('.gold').length, | |
p = parseInt((g/s) * 100); | |
return 'Out of a total of '+s+' skills, you have '+g+' gold ('+p+'% completed).'; | |
} | |
getDuolingoTreeProgress() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment