Console.exception

From FirebugWiki

(Difference between revisions)
Jump to: navigation, search
(Separate Console API page for console.exception())
m (Removed the dot after the output)
Line 17: Line 17:
</source>
</source>
-
This prints <code style="background-color: #FFEBEB; color: red;">[[File:error.png]] Exception.</code> to the console.
+
This prints <code style="background-color: #FFEBEB; color: red;">[[File:error.png]] Exception</code> to the console.
== See also ==
== See also ==

Revision as of 11:33, 18 November 2013

Prints an error message together with an interactive stack trace of JavaScript execution at the point where the exception occurred.

This is similar to console.error with the difference that only the first parameter will be used as name for the error message while the other parameters are logged in an array.

Contents

Syntax

console.exception(object[, object, ...])

Parameters

object

Object to output in the console. This can be any kind of object.

Examples

console.exception("Exception");

This prints Error.png Exception to the console.

See also

Personal tools