Created
December 4, 2019 07:53
-
-
Save seleb/25b60d596d1f7c50f28a77f59de00532 to your computer and use it in GitHub Desktop.
download tracks from https://soundcloud.com/you/tracks
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 wait(t) { | |
return new Promise(resolve => setTimeout(resolve, t)); | |
} | |
const tracks = Array.from(document.querySelectorAll(".trackManagerTrackList__item")); | |
for (track of tracks) { | |
const moreBtn = track.querySelector('.sc-button-more'); | |
moreBtn.click(); | |
await wait(500 + Math.random(500)); | |
const downloadBtn = document.querySelector('.sc-button-download'); | |
console.log(downloadBtn.download); | |
downloadBtn.click(); | |
await wait(500 + Math.random(500)); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment