Semantic markup
<form data-a11y-form-validator novalidate>
<input name="email" type="email" required />
<textarea
name="message"
required
minlength="10"
maxlength="180"
data-character-count
></textarea>
</form>
Start here
Semantic contact form with inline errors, a summary, grouped choices, and character count guidance.
Back to demo gallery
This demo combines semantic HTML constraints with the default preset and character count addon.
It uses the readable ./dist/index.js build; use the direct browser demo when you
want to inspect ./dist/index.min.js.
<form data-a11y-form-validator novalidate>
<input name="email" type="email" required />
<textarea
name="message"
required
minlength="10"
maxlength="180"
data-character-count
></textarea>
</form>
const preset = createDefaultPreset();
createFormValidator(form, {
...preset,
addons: [...preset.addons, createCharacterCountAddon()]
});