Skip to content

consoleCalls

Reports calls to console methods.

✅ This rule is included in the ts preset.

Console methods like console.log, console.warn, and console.error are useful during development but should typically be removed before shipping to production. They can expose sensitive information to users and clutter the browser console.

AEfuncti5<3 sp ansty="le--0:#82AAFF;--1:#3B61">B0processUs1<1(sp ansty="le--0:#D7DBE0;--1:#403F">53us7<2:sp ansty="le--0:#D6DEEB;--1:#403F">5<3 sp ansty="le--1:#1111"><11sp ansty="le--0:#FFCB">8BUsD53< {d ivclassNa="meec-li">53< sp ansty="le--0:#D6DEEB;--1:#403F">53consoAB0l5<3(sp ansty="le--0:#D9F5DD;--1:#1111">1<1"sp ansty="le--0:#ECC48D;--1:#984E">4DProcessing use1<1"sp ansty="le--0:#889FB2;--1:#4D66">753 user<);d ivclassNa="meec-li">nt< sp ansty="le--0:#C792EA;--1:#8844">AEretu53 usA72na5<3;d ivclassNa="meec-li">5<3}d ivclassNa="meco"><}d>
44AEfunc361B0process1<111( spans="tyle--0:#D7DBE0;--1:#40">3F5363<1111 spans="tyle--0:#FF">CB8BF<5DD) spans="tyle--0:#D6DEEB;--1:#40">3F<53 {divclass="Nameec-">de44AEre3F53 4<4AE. spans="tyle--0:#7FDBCA;--1:#09">6E7233

This rule is not configurable.

If your project intentionally uses console methods for logging in production, such as in a Node.js server application, you might choose to disable this rule. You might also disable it if you have a build step that strips console calls from production builds.