JSFiddle - React, Tailwind, and code Playground

HTML

<form>
    <input type="text" value="q" />

    <input type="text" value="3e" />

    <textarea rows="20" cols="20"></textarea>

    <input type="submit" value="submit" />

</form>

JavaScript

$( function(){
    var arr = $('form').find('input, textarea, select').map( function(){
        return this.value
    }).get()
            
    alert(arr.join(', '))
})