JSFiddle - React, Tailwind, and code Playground

HTML

<form id='myform'>
    <textarea id='c' name='x'></textarea>
    <input id='a' name='z' type='text' />
    <input id='b' name='y' type='hidden' />
    <input type='checkbox' id='f' name='s' >
    <input type='checkbox' id='f' name='d' >
    <select id='h' name='t'><option /></select>
</form>

JavaScript

console.log($("#myform *:input").map(function (i,e)
                         {
                             return {id: $(e).attr("id"),
                                     name: $(e).attr("name"),
                                     type: $(e).attr("type"),
                                     tag: $(e).get(0).tagName
                                    };
                         }
                         ));