You’re better off using Exceptions
My problem with exceptions isn&#x27;t so much exceptions themselves but the way they&#x27;re used.<p>The way I see it, exceptions should only be used for things that are irreconcilable, which most of the time is interpreter errors(e.g. undefined is not a function).  In other words, I don&#x27;t think it&#x27;s that common that custom exceptions are needed outside of assertions to prevent the developer from doing something stupid.  If you aren&#x27;t using types, raising an exception can be helpful to provide feedback and useful information when data isn&#x27;t formatted correctly.<p>Exceptions suck when they&#x27;re used for problems that aren&#x27;t actual problems.  For example, if a query is made to an API for a record and that record isn&#x27;t found, the SDK wrapping that API would raise a &quot;Record not found&quot; exception.  What the hell?  A record not being found is a <i>normal</i> thing!  I&#x27;ve seen this kind of thing all over the place, and I recently had to write some application code to work around one of these useless exceptions.  They literally tell you nothing and there&#x27;s no way to solve them without catching&#x2F;rescuing them.  A null value, a plain &quot;error&quot; object, or an error argument in a callback would have been sufficient.  If I need an exception to be raised for this kind of thing, I&#x27;ll do it myself.