I have been struggling with this issue for quite some time. I am working on a movie app and trying to implement a modal feature. Currently, I am able to display each movie individually along with their poster, title, and score.
The goal is to have the modal show up with the movie's description when the title is clicked. However, I am facing an issue where the modal only displays the description of the first object, regardless of which movie's title I click on.
When I remove the modal and add
<div>${overview}</div>
, it successfully shows the description of each movie as expected. But, once I try to put it back in the modal, it stops working correctly.
I have tried various solutions such as adjusting the onclick function and conducting thorough research online, but still haven't found a resolution. Any guidance or assistance would be greatly appreciated, thank you!
You can view the code here: https://github.com/sscip/movie-app-ms2