* feat: add ability to override custom levels compare
* fix: use function instead of closure
* docs: update level comparison to docs
* test: update types tests for level comparison
* refactor: move default levels and sorting order to constants
* fix: made suggested changes in pr review
* fix: change enum annotation type
* allow message prefix WIP
* fix tests
* trigger ci
* add tests
* added docs
* added support for msgPrefix for the root logger
* Update docs/api.md
Co-authored-by: James Sumners <james@sumners.email>
* revert change based on benchmark
---------
Co-authored-by: James Sumners <james@sumners.email>
* Make the nestedKey only take effect in the serialized object and fix error detection and serialization (closes#883)
proto.js
* Copy the message property in case the obj is an error and there is a msg specified
* Load the msg as a property of obj if metadata is needed
symbols.js
* Add nestedKeyStrSym to quickly cache the string
tools.js
* Manually build the stringify for performance reasons (not too pretty...)
error.test.js + serializers.test.js
* Add a test for the new nestedKey interaction
* Add tests to complete the coverage
* Address PR notes
* Fix test title
* Fix tests
Co-authored-by: Mihai Voicescu <mihaivo@intern.pch>
* deprecate the `changeLevelName` option and alias it to `levelKey`
* use process.emitWarning instead of console.warn for deprecation message
* avoid accessing private state in changeLevelName deprecation test
* Fix bug Global serializer not invoked for strings when `base: null`
* Remove unused symbol
* remove sting interpolation
Co-Authored-By: yellowbrickc <yellowbrickc@users.noreply.github.com>
* Instead of cloning the object parameter, the messageKey prop will be set if needed.