<div>

 

The <div> document division element is a block level element that acts as a container, encapsulating content and dividing the document into sections.

 

  • Starts a new line
  • Stretches across the width of its container
  • Acts as a container for other elements

 

CSS is generally applied to provide styling to a <div>, enabling all elements contained with the div to be styled at the same time.

 

Divs can be nested, and also as an example styled with CSS to say perform width adjustments or apply a specific font.

 

Save & refresh browser:

My first Heading

Paragraph one

Paragraph two

Paragraph three

Leave a Reply