The name property is used to either set or return the name of an error.
Its syntax is:- errorObj.name
Its return is:- name of error
There is a total of six different values that can be returned by error property. These are:-
|Error at execution.
|A number out of range has occurred
|An illegal reference has occurred
|A syntax error has occurred
|A type error has occurred
|An error in encodeURI() has occurred