Better track of javascript events with console log