A <div>
tag is a block-level element that starts on a newline
and stretches across the entire width of the page. You can use a
<div>
tag to apply styles to all the elements nested inside it.
A <span>
tag is an inline element that does not start a
newline and only takes up as much space as needed. You can use a
<span>
tag to apply styles to a particular element without disrupting
the flow of the other elements on the page.
<div>
tag to center a block
but not center the text within that block.
This is an example of a paragraph that contains custom styling for just a few words right in the middle of the sentence.
<div>
Tag<span>
Tag