CSS Comments

CSS Comments

To explain a code, the CSS comments are used. It makes code easy to understand. Comments are not displayed by the browsers. Both the single or multiple lines statement are written within the /*…………*/ in CSS.


<!DOCTYPE html>  
h3 {  
    color: crimson;  
    /* I am a single-line comment */  
    text-align: center;  
/* I am  
a multi-line  
comment */  
<h3>Hello World!!</h3>  
<h3>Today is a great day.</h3>   



In the above example, we displayed the use of both the single or multiple line comments in CSS.

Please follow and like us:
Content Protection by DMCA.com