Hi everyone this is my first question in this platform! currently im working on a website project and i’m facing some issue with my div container. I have inserted an image inside my container i expected the image to take full top space of my container but, for some reason there was some default padding in my container even though didn’t applied any padding property. Turns out browsers are applying some default padding with some other properties to my container, I tried with the !important property but doing that unstructures my whole page.
I was expecting that the image should cover the full top portion of my container but that didn’t work.I inspected my code and unchecked the padding property box and the padding was gone but it comes back when the refresh the page.
user28649149 is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.
Use width: 100% and height: 100% in your image tag class and see if this works. I often use Tailwind, and this issue doesn’t arise with me.