What to throw? Error or bare string dilemma
How Errors are inferior and superior to bare strings
Published in
4 min readNov 28, 2021
What is Error?
It is an ordinary class. The modern constructor of Error
has two parameters, both are optional:
new Error(message, options)