I think the following code will take care of only TextFields in the form:
var str = $('#formId').serialize();
To add other types of input type we can use:
$("input[type='checkbox'], input[type='radio']").on( "click", functionToSerialize );
$("select").on( "change", functionToSerialize );