HDTutorial
EN

Playback starts YouTube’s embedded player (privacy-enhanced mode).

CSS Comment | Part-4 | CSS Tutorial For Beginners | Tutorial007

37,494 views November 2, 2017 3:50

Watch on YouTube
ChannelTutorial007

Description from the creator

Welcome to Tutorial007 and in this video, we will learn about the comment in class. So stay tuned and watch how we can comment in css.

Watch: youtube.com/watch?v=Dp0atAZb950
#tutorial007 #css #commentInCss #cssTutorial #cssInHindi

CSS uses the same "block comment" syntax as the C-like languages - you start a comment with /*, and end it with */.
However, CSS is missing the "line comment" syntax that those languages have, where everything from // to the end of the line is commented out.
People have asked for this syntax to be added repeatedly, but unfortunately our hands are mostly tied - CSS minifiers don't know about line comments, so if we added it and the minifier removed all the line breaks (as they tend to do), the line comment would accidentally comment out the entire rest of your stylesheet!
That said, CSS does actually already allow you to use //, after a fashion. It's not quite a line comment, but a next construct comment.
That is, whenever you use //, the next CSS construct - either declaration or block - will be "commented out". For example:
.foo {
width: auto;
//height: 500px;
background: green;
}

css single line comment

css multi line comment

what type of css is used to format a single website page?

how do you add a background color for all h1 elements?

which property is used to change the background color?

css comment section

which css property is used to change the text color of an element?

which of the following selector matches all elements of a type?

Stay tuned to #tutorial007 and learn HTML,CSS,Javascript,Java,PL/SQL,Java,Jquery,MVC,web Development and many more..

SUBSCRIBE to our YouTube channel, visit to:
youtube.com/tutorial007

*********************************************
Follow Tutorial007 on Facebook
facebook.com/Tutorial007

*********************************************
Follow Tutorial007 on Instagram
instagram.com/Devian_rana

**********************************************
Subscribe Tutorial007 on YouTube
youtube.com/tutorial007
**********************************************

About this tutorial

Tutorial007 published this 3:50 video tutorial on November 2, 2017. It has been watched 37,494 times on YouTube.

Category
Education
Duration
3:50
Published
November 2, 2017
Views
37,494
Likes
339

Tags

Share

This tutorial in other languages