Table of contents Home page
Execute this code
try { if(confirm("Do you want to have an exception thrown?")) { throw new SyntaxError() } } catch(e) { alert('An exception of the type "' + e.name + '" was thrown.') }