How to useconsole.info() Method in Javascript
The console.info() method is used to write a message in the console. It indicates an important message about any element or object. The message is sent as a parameter to the console.info() method.
Syntax:
console.info( message )
Example:
Javascript
let str = [ "Welcome to w3wiki" ]; console.info(str); |
Output
[ 'Welcome to w3wiki' ]
How to Print a Message to the Error Console Using JavaScript ?
This article will show you how to print a message using JavaScript on the error console. There are three methods to display the error console, these are:
Table of Content
- Using console.error() Method
- Using console.warn() Method
- Using console.info() Method