Search code examples
node.jstypescriptfirebasechalk

Chalk would not log colored


Chalk does not log colored in Firebase logs, which I get by firebase functions:log, it should have some colors applied because of chalk; but it is not being applied.

I'm 100% sure chalk is installed.

Example:

import chalk from "chalk";
const success = chalk.greenBright;
success("Kabul lobisi oluşturuluyor..");

Solution

  • According to the Chalk documentation, you should be using:

    console.log(success("Kabul lobisi oluşturuluyor.."));
    

    The calls are still wrapped in console.log(...).