To ensure text breaks down onto the next line correctly when resizing the browser, it's useful to use a max-width
property. max-width
determines the absolute maximum width an element can expand to - it's useful for keeping elements in a confined space.
The max-width
property is typically applied to a "container" element, one that encapsulates multiple elements, typically containing some sort of text.
It can be a little hard to visualize how a container works just from text, so let's hop into the video where you can get a better idea of what containers look like and how to create them with max-width
.