File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -76,12 +76,16 @@ export function createLogger(
7676 allowClearScreen && process . stdout . isTTY && ! process . env . CI
7777 const clear = canClearScreen ? clearScreen : ( ) => { }
7878
79+ // extra space for rendering emoji correctly on Windows Terminal
80+ const isWindowsTerminal = ! ! process . env . WT_SESSION
81+ const emojiDivier = ' ' . repeat ( isWindowsTerminal ? 2 : 1 )
82+
7983 const logger : Logger = {
8084 level,
8185 options : resolvedOptions ,
8286
8387 info ( ...msgs : any [ ] ) : void {
84- output ( 'info' , `${ blue `ℹ` } ${ format ( msgs ) } ` )
88+ output ( 'info' , `${ blue `ℹ` } ${ emojiDivier } ${ format ( msgs ) } ` )
8589 } ,
8690
8791 warn ( ...msgs : any [ ] ) : void {
@@ -113,7 +117,7 @@ export function createLogger(
113117 } ,
114118
115119 success ( ...msgs : any [ ] ) : void {
116- output ( 'info' , `${ green `✔` } ${ format ( msgs ) } ` )
120+ output ( 'info' , `${ green `✔` } ${ emojiDivier } ${ format ( msgs ) } ` )
117121 } ,
118122
119123 clearScreen ( type ) {
You can’t perform that action at this time.
0 commit comments