2 ms·
"throw" takes the value to throw as an exception. An exception is an event which can be handled with "catch". [1] The standard refers to predefined errors such
by lobster_johnson 9y ago
"throw" takes the value to throw as an exception. An exception is an event which can be handled with "catch". [1] The standard refers to predefined errors such as TypeError as "exceptions".
[1] http://www.ecma-international.org/ecma-262/6.0/#sec-try-statement http://www.ecma-international.org/ecma-262/6.0/#sec-try-stat...