The error data property of a SuppressedError instance contains a reference to the error that results in the suppression.
Any value. Like cause, you cannot assume it's an Error instance, although it usually is the case.Property attributes of SuppressedError: errorWritable yes Enumerable no Configurable yes
try {
throw new SuppressedError(
new Error("New error"),
new Error("Original error"),
"Hello",
);
} catch (e) {
console.log(e.error); // Error: "New error"
}