<aside>
<aside>
Tag
The HTML <aside>
element is used to define content that is related to but separate from the main content. It is commonly used for sidebars, pull quotes, or advertisements. Information inside <aside>
can be removed without affecting the core content of the page.
Syntax
<aside>
<h1>Contents...</h1>
<p>Contents...</p>
</aside>
<aside>
Demo
My family and I visited the Epcot Center this summer. The weather was great, and Epcot was an amazing experience! I had a wonderful time with my family!
<h1>The <aside> Element</h1>
<p>My family and I visited the Epcot Center this summer. The weather was great, and Epcot was an amazing experience! I had a wonderful time with my family!</p>
<aside>
<h4>Epcot Center</h4>
<p>Epcot is a theme park at Walt Disney World Resort featuring exciting attractions, international pavilions, award-winning fireworks, and seasonal special events.</p>
</aside>
<aside>
element is commonly used to display sidebar content within a webpage layout.Purpose and Usage
The <aside>
element is designed to contain content that complements the main content while remaining separate from it.
It typically provides additional context or extra information that is relevant but not the primary focus of the page.
<aside>
element is widely used for sidebar content in web design.<aside>
element, but you can customize its appearance using CSS.Default CSS Settings
Most browsers render the <aside>
element with the following default styles:
aside {
display: block;
}
Conclusion
The <aside>
tag in HTML is used to define content that is related to but separate from the main content, such as sidebars, pull quotes, or advertisements. It provides additional context or supplementary information without disrupting the core content. By default, browsers don't apply special styles to it, but it can be customized with CSS.
<body>
The HTML <body> element encompasses the primary content of an HTML document, including text, images, and media, which is displayed in the browser for users.
<main>
The HTML <main> element signifies the primary content of a document, omitting headers, footers, and sidebars, and improves the semantic organization and accessibility of the document.