Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Express.js disable console color

When starting an Express webapp from Eclipse, output in console has strange characters:

[90mGET / [32m200 [90m310ms - 162b[0m

I guess they are "color" characters: when running express from a terminal, output is colorful.

How to disable color output from Express?

like image 853
Alessandro Pezzato Avatar asked Nov 06 '13 14:11

Alessandro Pezzato


2 Answers

You can pass your own format instead of dev. refer this: http://www.senchalabs.org/connect/logger.html

like image 96
Chirag Jain Avatar answered Oct 20 '22 02:10

Chirag Jain


I think the 'tiny' logging format is similar to the (colored) 'dev' format:

app.use(express.logger('tiny'));
like image 39
robertklep Avatar answered Oct 20 '22 02:10

robertklep