[removed] How do I print a message to the error console?

前端 未结 18 2177
闹比i
闹比i 2020-12-04 04:52

How can I print a message to the error console, preferably including a variable?

For example, something like:

print(\'x=%d\', x);
18条回答
  •  自闭症患者
    2020-12-04 05:18

    Visit https://developer.chrome.com/devtools/docs/console-api for a complete console api reference

        console.error(object[Obj,....])\
    

    In this case, object would be your error string

提交回复
热议问题