Recall & Review
beginner
What is the
sass:list module used for?The
sass:list module provides functions to work with lists in Sass, like adding, removing, or checking items.Click to reveal answer
beginner
How do you get the length of a list using
sass:list?Use the
length() function from the sass:list module to find how many items are in a list.Click to reveal answer
intermediate
What does
list.append($list, $value, $separator) do?It adds
$value to the end of $list. You can choose the separator (space or comma).Click to reveal answer
intermediate
How can you check if a value exists in a list with
sass:list?Use
list.index($list, $value). If it returns a number, the value exists; if null, it does not.Click to reveal answer
intermediate
What is the difference between
list.join() and list.append()?list.append() adds one item to a list. list.join() combines two lists into one.Click to reveal answer
Which function from
sass:list returns the number of items in a list?✗ Incorrect
length() returns how many items are in a list.What does
list.index($list, $value) return if the value is not found?✗ Incorrect
It returns
null if the value is not in the list.How do you add an item to the end of a list in Sass?
✗ Incorrect
list.append() adds an item to the end of a list.Which separator can you use with
list.append()?✗ Incorrect
You can choose space or comma as the separator.
What does
list.join($list1, $list2, $separator) do?✗ Incorrect
list.join() merges two lists into a single list.Explain how to add an item to a Sass list and specify the separator.
Think about the function that adds items and how you choose the separator.
You got /3 concepts.
Describe how to check if a value exists in a Sass list and what the result means.
Focus on the function that finds the position of a value.
You got /3 concepts.