I have been trying to get the Chrome console to clear, however it keeps giving me this error:
Uncaught TypeError: Object #<Console> has no method 'clear'
I honestly have no idea why it keeps giving me this error. console.log(...)
works and so do many other console functions, just not clear()
.
<!DOCTYPE HTML>
<html>
<head>
<script>
console.log("Hello, World.");
console.clear();
</script>
</head>
<body>
</body>
</html>
Any Ideas?
EDIT: https://developers.google.com/chrome-developer-tools/docs/console#clearing_the_console_history
states "Invoke console.clear() Console API from JavaScript." So I figured there was some way to use the clear() function from within a javascript script, but I guess I misunderstood.