- 🐛
3dbde57
Allow stream to be null - 🐛
d23708a
Improve log error typing - 🐛
de9d125
Fix missing base data when logging error only
Released by Maximilian Antoni on 2024-01-31.
Released by Maximilian Antoni on 2024-01-29.
- 🐛
88a50b7
Include error message in stack if name is missing - ✨
8510c8f
Run tests with local safari - ✨
318c73b
Expose stack helper on logger
Released by Maximilian Antoni on 2024-01-29.
- 🍏
45073bc
Always include error name and message in stack - 🍏
7b5934f
Add typescript - 🐛
03e6a5f
Remove broken error handler - ✨
dff39b6
Use new mochify with esbuild and upgrade mocha - ✨
2b22838
Add GitHub action - ✨
05886d9
Upgrade Studio Changes - ✨
770dc13
Upgrade referee-sinon - ✨
eb54bac
Upgrade eslint config and update eslint
Released by Maximilian Antoni on 2024-01-28.
With this release, Studio Log becomes a tiny 3.3KB library. Formatters and the
CLI have been moved to separate modules and with the new console
format,
Studio Log can be used in browsers too.
The most important API change is the removal of the default transform. Updated examples of how to configure the logger can be found in the README.
-
💥
3750908
BREAKING: Slim down API- Change
out
topipe
and let it return the stream instead of the logger. - Remove
transform
. Use stream pipes instead. - Remove
mute
andmuteAll
. Use a custom transform instead. - Remove
filter
. Use a custom trnasform instead. - Remove default transform. Add a serializing transform like Studio ndjson to the pipeline yourself.
- Change
-
💥
8da64cc
BREAKING: Extract format and CLI modules- Move topics into
@studio/log-topics
module - Move format into
@studio/log-format
module - Move emojilog into
@studio/emojilog
module
- Move topics into
-
📚
612f818
Document v2.0 API changes -
📚
eca4548
Improve "Transform streams" documentation -
📚
6096722
Use new Studio Changes--commits
feature -
✨
281934c
Add test runner for browser support -
✨
583ed68
Use Sinon + Referee
-
🐛 Adjust whitespace after emoji to be consistent
With Unicode 9 most emoji are rendered with the correct width now. Some still need an extra space though. This changes the spacing to make them look consistent.
-
🐛 Log all non-error related cause properties
Previously, only the
code
property of the cause error was logged. With this change any property that is notname
,message
orstack
is added to thedata.cause
object.
- 🐛 Handle error like objects correctly
-
🐛 Fix --map if chunks have multiple lines
When passing
--map sourcemaps.map
toemojilog
, the created transform stream expected each chunk to contain a single line. With this change, the sourcemaps lookup also works for multiline chunks. -
✨ Use Sinon 5 default sandbox
-
📚 Fix typo in message docs
-
🐛 Fix unwiring filters
Filters must be unwired before re-configuring. This refactoring also removes some duplication in reset.
- 🍏 Allow to add filters directly to a child namespace
-
🍏 Add source maps support
Use
--map source.js.map
to specify a source maps file.
- 🐛 Restore Node 4 compatibility
- 📚 Add
cause.js
example - 📚 Move
demo.js
into examples dir
- 🍏 Serialize the error
cause
as a new JSON property - 🍏 Serialize the error
code
into thedata
object - 🍏 Serialize the error
cause.code
into thedata
object - 🍏 Support the new
cause
property in the basic and fancy formatters - 📚 Add new feature to docs and improve usage example and API docs
- 📚 Add cause example to demo
- ✨ Add install instructions
-
🍏 Add global log filter stream support
A global filter stream can be configured which will receive all log entries before they are passed to the transform stream. This can be used to enrich the log data with generic environment information.
-
🍏 Add support for logger base data
When creating a logger, a
data
property can be passed which will be included in thedata
of each log entry. -
🍏 Add support for child loggers
Child loggers have their namespace joined with their parent by a blank and the
data
property of the parent and the child logger are merged. -
🍏 Add
mute()
to logger instance -
🐛 Do not invoke filters if out stream was removed
-
🍏 Add log instance filter stream support
Filters are object streams to modify the log data before passing it to the transform stream. They can be used to x-out confidential information or add generated information to log entries.
-
✨ Add npm 5
package-lock.json
The ndjson parsing and serialization was refactored into a separate module. This enables error handling for serialization failures.
- 🍏 Use the Studio ndjson parser transform
- 🍏 Handle transform error events. If a transform error occurs, an error message is logged instead of throwing up the stack.
- 🍏 Replace the internal default transform with the more robust implementation from Studio ndjson.
- ✨ Make log functions no-ops if no output is given. This avoids pointless
JSON.stringify
invocations and therefore improves performance a tiny bit.
🐛 Fix screenshot image to work outside of GitHub
🍏 Add hasStream()
to the API which returns whether an output stream was set.
Fixes and improvements for the fancy format transform.
- 🐛 Escape all non-printable characters. Print escape sequences, if available,
and fall back to hex values. Do not escape emoji
‼️ - 🐛 Escape newlines and tabs in strings (Fixes #3)
- 🐛 Format empty objects as
{}
without blanks (Fixes #1) - 🐛 Format primitive data values (Fixes #4)
🙈 Support Node 4
✨ Handle non-json prefix in emojilog
. Attempt to parse JSON starting from
the first occurrence of the {
character. Anything before that is forwarded to
stdout.
🐛 Make it work with local symlinks
🙈 Disabled by default
✨ Initial release