The community member is building a blogging site with WordPress and is trying to find the best way to implement a centered feature image that adjusts to different resolutions and sizes. They mention that using raw HTML and CSS to set the background image and center it would work, but they are unable to bind the background image. Another community member suggests using the Image component in combination with the object-fit property, which the original poster confirms worked for them.
I am building out a blogging site with Wordpress as the backend, and everything is going well, other than a few minor issues.
I am right now trying to figure out the best way to implement a feature image that's centered, regardless of its resolution or size.
If I was doing raw HTML in this situation, I would just set the background image, then use some CSS to center it, size cover, and get the exact result I need.
However, it appears I can't bind the background image.
Does anyone have any suggestions as to what I could do?