HTMLTextAreaElement: type property

The read-only type property of the HTMLTextAreaElement always returns textarea.

Value

A string whose value is always textarea.

Example

HTML

html
<textarea id="txtarea"></textarea>

JavaScript

js
const txtAreaElement = document.querySelector("#txtarea");
console.log(txtAreaElement.type); // Output: "textarea"

Specifications

Specification
HTML Standard
# dom-textarea-type-dev

Browser compatibility

desktopmobile
Chrome
Edge
Firefox
Opera
Safari
Chrome Android
Firefox for Android
Opera Android
Safari on iOS
Samsung Internet
WebView Android
type

See also