HTML <details> Tag
<details>tag specifies additional details that the user can view or hide on demand.
<details>tag can used to create an interactive widget that the user can open and close. Any sort of content can be put inside the
<summary>tag is used to specify a visible heading for the details. The heading can be clicked to view/hide the details.
- Example Code:
<details> <summary>About CSSPortal</summary> <p>CSSPortal is a site dedicated to helping you with CSS.</p> </details>
CSSPortal is a site dedicated to helping you with CSS.
Attribute Definition open Specifies whether the details should be open (visible to the user) or closed (hidden from the user).
- Global Attributes:
<details>tag also supports the Global Attributes in HTML5
- Event Attributes:
<details>tag also supports the Event Attributes in HTML5