Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What is ">ul" means in SASS?

Tags:

sass

stylus

Here is the SASS code part:

#main-nav{
     >ul{
              blahblah
        }
}

So I want to know the exact mean of the string ">ul" means? I cannot find it in the SASS manual.

Furthermore, can it be translated to stylus?

like image 658
nuk Avatar asked Aug 05 '13 14:08

nuk


People also ask

What does Li a mean in CSS?

How much do you understand about CSS? I ask because a selector like li a is very simple: it means any link (aka anchor tag) that is inside a list item (i.e. li). It follows, therefore, that ul li a means any link that is inside a list item that is inside an unordered list (ul).

What is the use of selector in SCSS?

The selector functions are used to check and manipulate selectors. Checks whether the super selector matches all the elements that sub matches.

What does mean SCSS?

What is SCSS? SCSS stands for the Sassy Cascading Style Sheets. The more advanced variant of CSS is SCSS. It was created by Chris Eppstein and Natalie Weizenbaum and designed by Hampton Catlin. It is also referred to as Sassy CSS due to its advanced features.

What is @content in sass?

The @content, aka content directive, is “simple” in that it provides a way to reduce repetitive code, allowing for reuse and easier changes throughout the codebase.


1 Answers

This the CSS syntax to select the child of an element. See this reference for more on how it works:

This selector matches all elements that are the immediate children of a specified element. The combinator in a child selector is a greater-than sign (>). It may be surrounded by whitespace characters, but if it is, Internet Explorer 5 on Windows will incorrectly treat it as a descendant selector. So the best practice is to eschew whitespace around this combinator.

like image 164
Burhan Khalid Avatar answered Oct 05 '22 03:10

Burhan Khalid