Last active
October 16, 2021 17:43
-
-
Save metaphore/291af68f0d8281c7333c6eb1d5b783b0 to your computer and use it in GitHub Desktop.
Chrome bookmarklet to display latest release download count for https://github.com/crashinvaders/gdx-texture-packer-gui project.
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
data:text/html,<script> | |
fetch('https://api.github.com/repos/crashinvaders/gdx-texture-packer-gui/releases').then(response => { | |
response.text().then(responseText => { | |
let parsedResponse = JSON.parse(responseText); | |
let content = parsedResponse[0].assets.map(asset => ({ | |
file: asset.name, | |
downloads: asset.download_count | |
})); | |
let htmlContent = JSON.stringify(content, null, 4); | |
alert(htmlContent); | |
}) | |
}) | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment