Hacker News new | ask | show | jobs
by omnimus 895 days ago
It's not different. The question is if we would have current JS capabilities in the past would we choose adding handling of <form> to HTML or would we say use JS for that. I am not sure what is the right answer but adding features to both sides is probably not a great idea because you just bloat everything.
1 comments

It's a language paradigm thing. You can implement anything, from HTML to CSS, in pure imperative JS, but the result would be extremely verbose and virtually impossible for machines to interpret on the fly (i.e. little accessibility support).

There is concrete value in stating unambiguously "this is a <form>" versus "this is a blob of imperative code that I swear acts like a <form>".