-
-
Notifications
You must be signed in to change notification settings - Fork 219
Description
I have developed several vscode extensions that put invisible unicode chars in lines so I can find lines my extension generated. This is the same problem that turbo log solved by using the 🚀prefix. But if you wish you can specify an invisible prefix to remove that ugliness from your logs.
I use the zero-width space \u200B as my prefix. You can copy the char from inside these brackets: []. You can verify it is there by using an arrow key to move the cursor over it. It will seem like the arrow key is broken when it doesn't move at that char. Just hold the shift key down while stepping "over" the char to copy it to the clipboard and paste into the prefix setting.
Note: vsCode has a setting to show invisible chars by showing a tiny rectangle. It defaults to true but you can turn off that setting. If you do turn it off be careful not to edit the log line in such a way the the invisible char gets lost in your code. You will get confusing syntax errors. I have used this technique in my extensions with the vsCode setting turned off and I've never had a problem.
Enjoy ...