-
Hi! I'm using the amazing new gatsby-plugin-image. Now I would like to add a (CSS-styled) text overlay on top of my image. What would be the best approach to guarantee that this overlay
|
Beta Was this translation helpful? Give feedback.
Answered by
LekoArts
Apr 20, 2021
Replies: 1 comment 1 reply
-
You could follow this guide: https://www.gatsbyjs.com/docs/how-to/images-and-media/using-gatsby-plugin-image#background-images I mostly did it this way in the past (when CSS grid wasn't so widely supported):
|
Beta Was this translation helpful? Give feedback.
1 reply
Answer selected by
ronaldvdv
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
You could follow this guide: https://www.gatsbyjs.com/docs/how-to/images-and-media/using-gatsby-plugin-image#background-images
I mostly did it this way in the past (when CSS grid wasn't so widely supported):
relative
containerabsolute
position to display text div over image + add styling to expand it to the size of the relative parent