Where Did the Songs Go? (Loading Related Data)
You’ll learn about specifications of the network response and how to update the model hook to fetch songs in this lesson.
Network response from JSON:API
The app seems fine, but we quickly realize that songs are not correctly loaded for any of the bands. When we click any of the band links in the sidebar, no songs are displayed. Taking a look at the network response for /bands
in below image, we see a relationships
attribute for each band item. Digging further down, we find a URL for the songs
relationship where related records should be loaded from. However, no request is made to any of ...
Access this course and 1400+ top-rated courses and projects.