Open
Description
I've been looking at the Error module. It is hard to raise exceptions because each of the different types are exposed in sub-modules like Error.SyntaxError
that contain a single function - raise
. At a glance you can't tell what the different types of exceptions are and must navigate into the sub-module to do it. The Intellisense menu looks like this...
I much prefer the Js.Exn
way of doing it.
I notice an Error.make
function. Is there anything you can do with it before raising it? Because if not, just remove make
and go straight to throwing. If we want the ability to add custom properties first, I'm not sure how you'd do that. Consider adding some of the get
and set
functions from Object
or convert to object.
Metadata
Metadata
Assignees
Labels
No labels