concordancejs / concordance

Compare, format, diff and serialize any JavaScript value
ISC License
207 stars 15 forks source link

Add option to always format error messages #77

Open novemberborn opened 3 years ago

novemberborn commented 3 years ago

Concordance ignores non-enumerable properties. AVA uses Concordance to format caught errors. If a custom error is created with a non-enumerable message then this message is not included in the results.

IIRC we already handle name properties of errors, so we could include non-enumerable message properties by default (this would be a breaking change) or by configuration.

See also https://github.com/avajs/ava/issues/2755.