Skip to content

Release 3.0.0

Compare
Choose a tag to compare
@ehmicky ehmicky released this 20 Nov 20:10
· 320 commits to main since this release

Breaking changes

  • BaseError.toJSON() was renamed to BaseError.serialize()
  • BaseError.fromJSON() was renamed to BaseError.parse()
  • When serializing/parsing a value that is not an error instance or an error plain object, it is now automatically converted to one

Features

  • Added the shallow option to serialize/parse shallowly
  • Added the loose option to prevent converting the argument to an error instance or an error plain object if it is not one