HTML DOM DetailsObject
Details Object
The Details object represents an HTML <details> element.
Access the Details Object
You can use getElementById() to access the <details> element:
var
x = document.getElementById("myDetails");
Try it Yourself
Create a Details Object
You can create a <details> element by using the document.createElement() method:
var x = document.createElement("DETAILS");
Try it Yourself
Details Object Properties
| Property | Description |
|---|---|
| open | Sets or returns whether the descriptive information inside the details tag is displayed. |
Standard Properties and Events
The Details object also supports the standardattributesandevents。
Related Articles
HTML Reference Manual:HTML <details> Tag
Other Extensions