I want to transfer all information of an event to a server. To do so I would need to serialize the event.
This is what I tried:
var element = document.QuerySelector('div');
element.addEventListener('click', function(event) {
console.log(event);
console.log(JSON.stringify(event));
}, false);
But all I get is an empty dictionary: {}
Is there any way to serialize an event object in a cross browser manner?