Console:
A console is a tool or panel that developers use to record the output of their JavaScript programs. The command console.log() is used to print, or log, text to the console.
Consider the following example:
console.log("Hello");
The output will show in the browser console as ''Hello" without the double quotation.
We can denote the end of the line with a semicolon. Without a semicolon, it will work but a semicolon is the best practice.
Here, the console refers to the object and the log is a method.
Post a Comment