Console clear()
Definition and Usage
The clear()
method clears the console.
The clear()
method also write "Console was cleared" in the console.
Syntax
console.clear()
Browser Support
console.clear()
is supported in all browsers:
Chrome | IE | Edge | Firefox | Safari | Opera |
Yes | Yes | Yes | Yes | Yes | Yes |