Methods
This section describes the methods associated with the Console Debugging API.
In this section
| Topic | Description |
|---|---|
|
Sends a message to the console if the expression provided evaluates to false. The message text color is red and it is prefaced by an error icon. | |
|
Clears messages from the console. | |
|
Create an incrementable counter that prints its value to the console. Use different countTitle parameters to create different counters. | |
|
An alias of console.log. | |
|
Prints the properties of an object to the console. | |
|
Logs an XML node object to the console. | |
|
Sends an error "message" to the console. The message text color is red and it is prefaced by an error icon. | |
|
Begins a collapsible group of console output. Initially displays expanded. | |
|
Begins a collapsible group of console output. Initially displays collapsed. | |
|
Ends the grouping started with a group or groupCollapsed method. | |
|
Sends an informational "message" to the console. The message is prefaced by an information icon. | |
|
Sends a log "message" to the console. The message is prefaced by the string "LOG". | |
|
Retrieves a Boolean value indicating whether the element is independently composed. | |
|
Starts recording profile information under the optional title provided. This command is equivalent to clicking the Start profiling button on the F12 developer tools Profile tab. | |
|
Stops recording profile information under the last report title. | |
|
Starts a timer. If you do not specify a name parameter, the name "default" will be used. | |
|
Ends a timer that was set using console.time() and logs the elapsed time to the console. If you do not specify a name parameter, the name "default" will be used. | |
|
Outputs a timestamp to the Console based on how long the current browser tab has been open. If used while a UI Responsiveness profiling session is recording, it will also create a user mark in the session timeline similar to a performance.mark. | |
|
Logs a stack trace to the console. | |
|
Sends a warning message to the console. The message is prefaced by the warning icon. |