DOM Properties

HTMLInputElement.willValidate

Build a form with the HTML form generator

Read-only. Indicates whether this control participates in constraint validation. Disabled controls and certain input types are excluded. A false value does not establish that submitted application data is safe. Example result: false.

Formal Syntax & Structure

html syntaxhtml
element.willValidate

Return Value

boolean

Property value. Read-only.

Working Example

Example Snippethtml
<input id="demo" required disabled><p>  Result:  <output id="result"></output></p><script>  const e = document.getElementById('demo');  const result = value => { document.getElementById("result").textContent = String(value); };  result(e.willValidate);</script>
HTML Reference