Skip to main content
Version: 3.45.0

Error.prototype.toString()

The toString() method returns a string representing the specified Error object.

Syntax​

toString()

Return value​

A string representing the specified Error object.

Description​

The Error object overrides the Object.prototype.toString() method inherited by all objects.