简体   繁体   中英

eslint and nodejs console messages

I have just started to use eslint and when running part of my application that visits various web pages I get console Messages like so printed out in the console

ConsoleMessage {
 _type: 'warning',
 _text: 'Extra form data if value attribute is present with non-empty value for <input type=\'image\'> is deprecated and will be removed in M68, around July 2018. See https://www.chromestatus.com/features/5672688152477696 for more details.',
 _args: [] }

I have tried the following in my .eslintrc.js

"no-console": 0

But I still get these messages, how do I suppress this ?

Thanks

The message doesn't have anything todo with eslint and it's no-console rule. The message is a warning from Google Chrome about some deprecated code .

As you point out you are 'visiting various websites' from within your application, I guess you are probably using something like puppeteer and the message might be output of this . Which would imply it is a Google Chrome warning of deprecated code from a website you are visiting.

To answer your question about suppressing these messages, you shouldn't log these console events, however I can't be sure as I haven't seen your code.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM