Overlay text above image inside a loop in react

If you want the <p></p> part appear above the <img> part, then you can enclose both in a div like this <div> <img><p></p> </div>, then add position: abosolute styling for <p> tag

Edit: I just tested this and found that paragraph <p> tag needs to be infront of img tag for this to work properly. i.e <div> <p></p><img> </div>

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top