HTMLTextAreaElement: wrap property - Web APIs | MDN

Value

See wrap for the possible values. Defaults to "soft".

Examples

js

const textareaElement = document.getElementById("comment");
const oldWrap = textArea.wrap;
textArea.wrap = "hard"; // Add line breaks (CR+LF) during form submission

Specifications

Specification
HTML
# dom-textarea-wrap

Browser compatibility

See also

Help improve MDN

Learn how to contribute

This page was last modified on by MDN contributors.