You're working on a navigation menu where each list item should be displayed side by side. How would you achieve this using CSS?
- Using the display: block; property.
- Using the display: flex; property.
- Using the display: grid; property.
- Using the display: inline; property.
To display list items side by side in a navigation menu, you should use the display: flex; property on the parent container of the list. This allows for a horizontal layout of the list items.
Loading...
Related Quiz
- The CSS unit vh represents a percentage of the ________.
- You want to set a global color scheme for a website using CSS variables. Where would be the best place to define these custom properties?
- How can you ensure that text remains visible during webfont load?
- The ________ property in CSS specifies how overflows should be handled when the content overflows its block container.
- In CSS, if you want an element to inherit a property's value from its parent element, you would use the value ________.