Advertisement
gopro2027

Apple Music Playlist Dumper

Dec 9th, 2022 (edited)
1,864
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. pull up an apple music playlist like https://music.apple.com/us/playlist/.../...
  2. Use the chrome extension "run javascript"
  3. enter in this code and run it. Check the console for the output.
  4. Enter list into https://www.spotlistr.com/search/textbox to create a spotify playlist
  5.  
  6. var all = $(".songs-list-row__song-name-wrapper").map(function() {
  7.     let data = "";
  8.     let i = 0;
  9.     for (child of this.children) {
  10.         i = i + 1;
  11.         try {
  12.         while (child.hasChildNodes()) {
  13.             let child2 = child.children[0];
  14.             if (child2 == undefined)
  15.                 break;
  16.             child = child2;
  17.         } } catch (err){}
  18.         data = child.innerHTML + data;
  19.         if (i == 1) {
  20.             data =  " - " + data;
  21.         }
  22.     }
  23.     return data;
  24. }).get();
  25.  
  26. console.log(all.join("\n"));
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement