Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
"W": term.str.bgBrightWhite() ,
"y": term.str.bgYellow() ,
"Y": term.str.bgBrightYellow()
}
}
} ;
term.formatConfig.rawMarkupConfig = Object.create( term.formatConfig ) ;
term.formatConfig.rawMarkupConfig.startingMarkupReset = false ;
term.formatConfig.rawMarkupConfig.endingMarkupReset = false ;
for ( k in term.escHandler ) { term.formatConfig.fn[ k ] = term.escHandler[ k ] ; }
for ( k in term.escOffHandler ) { term.formatConfig.fn[ k + '_off' ] = term.escOffHandler[ k ] ; }
term.format = string.createFormatter( term.formatConfig ) ;
term.markup = string.createMarkup( term.formatConfig ) ;
term.options = options ;
// Should come after any escape sequence definitions
createOptimized( term ) ;
// Register various exit handler
// Fix the issue #3, turn grabInput off on exit
// Disable input grabbing at exit.
// Note: the terminal can still send some garbage if it was about to do it when exit kickin.
process.on( 'exit' , () => {
//console.log( '>>> exit' ) ;
// Cleanup was done from elsewhere, probably by .asyncCleanup()
if ( term.shutdown ) { return ; }
term.shutdown = true ;
term.styleReset() ;