Closed aymanbagabas closed 1 year ago
Merging #39 (9d3304c) into main (65ede51) will increase coverage by
2.93%
. The diff coverage is79.29%
.
@@ Coverage Diff @@
## main #39 +/- ##
==========================================
+ Coverage 66.66% 69.60% +2.93%
==========================================
Files 12 11 -1
Lines 627 579 -48
==========================================
- Hits 418 403 -15
+ Misses 192 161 -31
+ Partials 17 15 -2
Impacted Files | Coverage Δ | |
---|---|---|
options.go | 0.00% <0.00%> (-66.67%) |
:arrow_down: |
styles.go | 71.42% <ø> (+28.57%) |
:arrow_up: |
text.go | 56.89% <66.66%> (-0.40%) |
:arrow_down: |
logger.go | 79.39% <79.26%> (+79.39%) |
:arrow_up: |
pkg.go | 64.78% <87.50%> (+19.55%) |
:arrow_up: |
context.go | 100.00% <100.00%> (ø) |
|
json.go | 78.72% <100.00%> (ø) |
|
logfmt.go | 78.94% <100.00%> (ø) |
|
stdlog.go | 76.19% <100.00%> (+1.19%) |
:arrow_up: |
terminal.go | 0.00% <0.00%> (-40.00%) |
:arrow_down: |
... and 4 more |
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.
BREAKING CHANGES
The current implementation pollutes the public namespace by adding logger options like
WithLevel()
,WithPrefix()
, etc. This creates a problem where the global namespace methods are shared between the log options and the singleton methods. Method name clashes can occur if we want to reuse the same name for both a log option and the global singleton instance. For example, adding aWithPrefix()
method to the log interface to return a new sub-logger would clash with the existingWithPrefix()
option.Add
Options{}
Remove Logger interfaceExample: