Represents a runtime error.
|Error||Represents a general error.|
|RangeError||Represents an error where a value is not in the range of allowed values.|
|TypeError||Represents an error where a value is not of the expected type.|
|SyntaxError||Represents an error where the syntax of the input in invalid.|
Errorclass can also be sub-classed by forwarding
message and setting the
name property in the overloaded constructor.
- Constructs a new error object.
new Error(message?: string)
# Instance members
var message: string
The message of this error.
var name: string
The name of this error. In case of
Error, this is
var stack: string
The stack trace of this error. Not supported yet, hence an empty string.
- Returns a string representation of this error in the form
function toString(): string