I know in CSS we use /* */
for comment text . But I see in some CSS use /*! some url or text */
.
What's different between /* text */
and /*! text */
?
How to Comment in CSS. To comment in CSS, simply place your plain text inside /* */ marks. This tells the browser that they are notes and should not be rendered on the front end.
Comments in CSS can be added by using the /* tag, which is then closed off by using */ . Note: Code that is commented out is not used to style the page. This technique can be used to add both single and multi-line comments.
The exclamation mark is to keep an comment important . This comment will not be deleted while compressing. This is important e.g. for keep a licence in a CSS file after compressing. Uglify or YUICompressor will keep that comment after compressing.
/*! important comment will not be deleted while compressing */
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With