tahsharaboochee / MoodLifter

0 stars 0 forks source link

Playlist creation logic belongs on the server #11

Open vegetabill opened 4 years ago

vegetabill commented 4 years ago

In terms of architecture, all the logic around constructing the mood-based playlists belongs on the server, not in the React app.

This might also help with having to manage nested promises, as the React app could just be given the finished playlist ID/URI in the response.

vegetabill commented 4 years ago

After seeing the code more, I'd suggest only creating a single playlist on demand if possible, to avoid hitting 429 throttling

vegetabill commented 4 years ago

I would also check if there is a way to fetch multiple songs in one request to avoid having like ~100 requests on page load, also to avoid 429