5

When ever I use console.clear() it says in console, "Console was cleared. Is there a way to clear the console without this outputting?This is what apears

Jak
  • 162
  • 2
  • 11

2 Answers2

0

It's not ideal but you could print a bunch of blank lines like so:

console.clear();
console.log(Array(100).join("\n"));
Rocky Sims
  • 3,523
  • 1
  • 14
  • 19
0

If you just want to clear the console messages, why not try the CtrlL shortcut, it works well.

Pablo
  • 5,897
  • 7
  • 34
  • 51
Gyumeijie
  • 174
  • 7
  • I have same question because the console is a part of my app. Console for customers to debug, not developer. – LE SANG Jan 05 '20 at 14:43
  • en, I think there must exist some way to clear message in the console, maybe it is invoking some api, but not by hitting the Ctrl + L, you need do some further search – Gyumeijie Feb 01 '20 at 08:11