index.js
function warn() {

  if(suppressWarnings) return

  var args = NS ? [chalk.bold.gray(NS)] : []
  for(var i=0; i<arguments.length; i++) {
    var arg = arguments[i];
    args.push(chalk.bold.yellow.bgRed( typeof arg === "object" ? JSON.stringify(arg) : arg ))
    
    // adds a separator
    if(i < arguments.length-1) args.push(chalk.gray("|"));
  }
  if(testWarn)  testWarn(args);
  else          console.warn.apply(null, args)
}
function warn() {

  if(suppressWarnings) return

  var args = NS ? [chalk.bold.gray(NS)] : []
  for(var i=0; i<arguments.length; i++) {
    var arg = arguments[i];
    args.push(chalk.bold.yellow.bgRed( typeof arg === "object" ? JSON.stringify(arg) : arg ))
    
    // adds a separator
    if(i < arguments.length-1) args.push(chalk.gray("|"));
  }
  if(testWarn)  testWarn(args);
  else          console.warn.apply(null, args)
}
function warn ( ) { if ( suppressWarnings ) return var args = NS ? [ chalk . bold . gray ( NS ) ] : [ ] for ( var i = 0 ; i < arguments . length ; i ++ ) { var arg = arguments [ i ] ; args . push ( chalk . bold . yellow . bgRed ( typeof arg === "object" ? JSON . stringify ( arg ) : arg ) ) // adds a separator if ( i < arguments . length - 1 ) args . push ( chalk . gray ( "|" ) ) ; } if ( testWarn ) testWarn ( args ) ; else console . warn . apply ( null , args ) }
coloured console warn
coloured console warn