I want to throw some things in my JS code and I want them to be instanceof Error, but I also want to have them be something else.(我想在我的JS代码中抛出一些东西,我希望它们是instanceof Error,但我也想让它们成为别的东西。)
In Python, typically, one would subclass Exception.(在Python中,通常会有一个子类Exception。)
What's the appropriate thing to do in JS?(在JS中做什么是合适的?)
ask by Josh Gibson translate from so
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…