Briefly describe the use of important property in CSS? And can you explain me with the example.
What is the use of important property in CSS?
305
12-Jul-2021
Ethan Karla
13-Jul-2021The important property of CSS is used for giving the priority to any property of a CSS. The !important property means 'That is important' means deny all the properties of that attribute and apply this important rule and value on that particular element.
The !important keyword must be applied at the end of the line otherwise it will not work if any below line code execute after that
Let's understand it with the help of an example :
Here, you can see that the Margin Bottom property overwrites the Margin property due to the !impotant property.
Hope you'll get understand if you have read it carefully.