I’m working on a movie recommendations web app, but I’m having trouble getting images from the backend to display on the frontend. When I directly use the image path, like this:
<img src={http://localhost:8000/images/Jailer.jpg
} alt={item.movieName} />
I can see the image of “Jailer” from the backend. But when I comment that line out and instead use item.movieImage, like this:
<img src={http://localhost:8000/images/${item.movieImage}
} alt={item.movieName} />
the image doesn’t render. In the tag, I’m seeing “Jailer.jpeg”, so I know the image path is correct. I’ve tried to debug this, but I can’t figure out why it’s not working. Could you please help me out?
I don’t know to do can anyone help me guys?