Created
March 4, 2022 20:28
-
-
Save pixeldesu/5bcdcc9d0963114592e637b2de9ff5b5 to your computer and use it in GitHub Desktop.
Small script to get the (almost) total of tracks present in an entire Bandcamp collection
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
/* Open your (or any other) Bandcamp profile, press the "show all x items" button and scroll to the very bottom of the | |
* page, with this you populate the collection item cache which we then can use to mess around with data | |
*/ | |
let tracks = 0; | |
(Object.values(ItemCache.collection)).forEach((tra) => { | |
tracks += parseInt(tra.num_streamable_tracks) | |
}); | |
console.log(`Your collection contains ${tracks} streamable tracks (this means the actual track count might be slightly higher)`); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment