Serialize an HTML Form to a JavaScript Object, supporting nested attributes and arrays.