Thank you https://codepen.io/jlengstorf/
A plain JavaScript example of extracting a form's fields into an object using the field name as the key and the field value as the value. This can work in lieu of things like jQuery's .serialize()
or .serializeArray()
, which leave something to be desired if we need to work with the form data in JavaScript.
Top comments (0)