How could one check if the user enters something in the console? I want a function to run whenever a user enters something in the console, say
function whenUserTypesInConsole() {
alert('you entered something in the console');
}
and if that can be done, is there a way to check what the user entered
function whenUserTypesInConsole(entry) {
alert('you entered ' + entry + ' in the console');
}
I would like to avoid using jQuery or any library if possible.
Thanks