Learn Basic String and Array Methods by Building a Music Player - Step 27

Tell us what’s happening:

Another blunder here

Your code so far

<!-- file: index.html -->

/* file: styles.css */

/* file: script.js */
// User Editable Region

const sortSongs = (songs) => {
  return songs.sort((a, b) => a.title.localeCompare(b.title));
};


// User Editable Region

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/18.0.1 Safari/605.1.15

Challenge Information:

Learn Basic String and Array Methods by Building a Music Player - Step 27

Any assistance from anybody?

what blunder are you having?

I solved it now I’m gradually working my way into javascript, what do you think of this one? Step 29 same topic, {
userData?.songs.sort();
songs.sort(() => {});
} what’s missing here?Preformatted text

I think that if you need help with a different step you need to open a new topic. But I think that you have two sort methods applied to two different things, one with an empty callback

Check my latest post for step 29.