Error message association (error-association)
Ensure each error message references its corresponding input (e.g.,
via aria-describedby)
Missing error association:
This error message is visually near the
<input> but not in any way
programmatically linked:
The (DOM/programmatic) structure of the erroneus input field above looks
like this:
<label for="text">Type something here:</label>
<input type="text" name="text" aria-invalid="true"
placeholder="Type something here" />
<br />
<p class="error">
The field above is erroneus (this is a sample error message).
</p>
Note: Hard to automatically test or detect. Requires a human tester or AI
to determine if error messages can be considered properly linked & placed.