const loginForm = document.getElementById("login-form");
loginForm.addEventListener("submit", handleSubmit);
function handleSubmit(e) {
e.preventDefault();
const formData = new FormData(e.target);
const formProps = Object.fromEntries(formData);
}
const form = document.querySelector('form');
const data = new FormData(form);
var formData = new FormData();
fromData.append('name','value');
// return data in key value pair
$('#form').serializeArray().reduce(function(obj, item) {
obj[item.name] = item.value;
return obj;
}, {});
var nameValue = document.getElementById("uniqueID").value;
var formData = new FormData();
const formData = new FormData([form]);