HTML DOM Element isContentEditable attribute
- Previous page insertBefore()
- Next Page isDefaultNamespace()
- Go to the Previous Level HTML DOM Elements Object
Definition and usage
isContentEditable
The property returns whether the element content is editable. This property is read-only.
If the element content is editable isContentEditable
Property returns true
.
Tip:Please use the contentEditable attribute to change the editable state of the element.
See also:
Example
"myP" element is editable:
let answer = document.getElementById("myP").isContentEditable;
Syntax
element.isContentEditable
Return value
Type | Description |
---|---|
Boolean value | If the element content is editable, it returns true; otherwise, it returns false. |
Browser support
All browsers support element.isContentEditable()
:
Chrome | IE | Edge | Firefox | Safari | Opera |
---|---|---|---|---|---|
Chrome | IE | Edge | Firefox | Safari | Opera |
Support | Support | Support | Support | Support | Support |
- Previous page insertBefore()
- Next Page isDefaultNamespace()
- Go to the Previous Level HTML DOM Elements Object