Visual Difference between Block and Inline Elements

About Paris

Paris is the capital of France and is called the City of Light. One of the most popular attractions is the Eiffel Tower.

Visitors also enjoy the Louvre Museum, Notre-Dame Cathedral, and delicious French cuisine.

Explanation

Block-level elements like <section>, <h2>, and <p> are shown with a blue background. They take the full width of the page.

Inline elements like <span> and <a> are shown in yellow. They only cover the text inside them and do not break into a new line.

AFTER REPLACING

About Paris

Paris is the capital of France and is called the

City of Light

One of the most popular attractions is the

Eiffel Tower

Visitors also enjoy:

Louvre Museum
Notre-Dame Cathedral

and delicious French cuisine.