+ 1

How to do the cleaning

I was sitting and making my own mini-site, well, just for myself, but how did I need to clean up the console? I tried to do it through "console.log('\n'.repeat(999));" but it clears only the bottom text and not the top, and that's why I'm here! (The "console.clear()" command is not suitable!!!)

27th Sep 2025, 12:30 PM
Ndns AIM
Ndns AIM - avatar
6 odpowiedzi
+ 3
Hi, Bob_Li! I think he was referring to clearing the browser console (in developer mode). I did some research today and found that there is no definitive solution. Different browsers clear their console in different ways 🤷‍♂️🤔
28th Sep 2025, 12:12 AM
Yaroslav Vernigora
Yaroslav Vernigora - avatar
+ 2
Yaroslav Vernigora you might be right. I was thinking of NodeJS. if it's the developer mode, the browser console usually have a trash icon you can click to clear the console. or it can be programmatically cleared by adding console.clear(); to your code.
28th Sep 2025, 12:25 AM
Bob_Li
Bob_Li - avatar
+ 1
mac: keyboard shortcut: Command + K or type clear press enter linux: keyboard shortcut: Ctrl + L or type clear press enter windows: type cls press enter you can't clear the "console" in Sololearn, though, because it's a fake one.
27th Sep 2025, 11:52 PM
Bob_Li
Bob_Li - avatar
0
Ооо русский
27th Sep 2025, 4:00 PM
Ndns AIM
Ndns AIM - avatar