DEV Community

Discussion on: Form Validation: You're (likely) doing it wrong

Collapse
 
dexygen profile image
George Jempty

HTML5 provides the very barest of validation, scripts are still required for anything industrial-strength.

Collapse
 
bgadrian profile image
Adrian B.G.

True, but is a start, a foundation which you build, and is often missing from articles about form validation.
I just want to remind the readers that they should start with HTML5 APIs and CSS3 then build on top of them.

Thread Thread
 
dexygen profile image
George Jempty • Edited

HTML5 validation is not going to help whatsoever -- not even as a foundation -- with a) the sorts of validation referred to in the article linked to at the top of my post, or b) in my example i.e. avoiding error messages when shift-tabbing to correct a previous error. HTML5 validation doesn't providing anything "holistic" like that; that's why mention of it is missing from my post.

Thread Thread
 
worc profile image
worc • Edited

it does seem like you're missing the use of html5 validation here. it can provide the basic is this valid value to higher-level concerns like should we display an error yet. the code examples here are pretty rough/imperative around the edges without it.

Thread Thread
 
dexygen profile image
George Jempty • Edited

The point of my examples are to quickly (without regard for it not being declarative, which I know a thing or two about, see: dev.to/dexygen/accidentally-declar...) emulate what's going on in the article linked to at the very top -- please read it if you haven't. And using HTML5 validation is like crossing a river on a bridge that doesn't even go half way across. Building the rest of the bridge to link up is not ideal, just better to build an entire bridge to your exact specifications to begin with.

Thread Thread
 
worc profile image
worc

i guess i would take a different analogy and say that html5 validation is more like sinking pylons into the river bed / bedrock so that you can run a more fully-featured roadway across the river.