- add godoc for SameLevel and Equal - update package docs and READMEs with new helpers - refresh unreleased release notes - add tests for Printf, HTTP method levels, and level constructors
This commit is contained in:
+5
-2
@@ -1,6 +1,6 @@
|
||||
# v2.2.0
|
||||
# Unreleased (planned v2.2.0)
|
||||
|
||||
This release adds new public APIs for working with log levels, introduces HTTP method-specific log levels, and improves package documentation.
|
||||
This release expands the public LogLevel API, adds HTTP method helpers, and improves package documentation and test coverage.
|
||||
|
||||
### Added
|
||||
|
||||
@@ -28,15 +28,18 @@ This release adds new public APIs for working with log levels, introduces HTTP m
|
||||
- `HTTPUnknownLevel`
|
||||
- Added `LogLevelForMethod(method string) LogLevel` to map HTTP methods to predefined log levels.
|
||||
- Added `Logger.Printf(level, format, args...)` for formatted logging with an explicit log level.
|
||||
- Added `LogLevel.SameLevel` and `LogLevel.Equal` for severity-only and full level comparisons.
|
||||
|
||||
### Changed
|
||||
|
||||
- Refactored log level definitions into a dedicated `levels.go` file.
|
||||
- Unified `Logger.Print` and `Logger.Println` through a shared internal implementation without changing their behavior.
|
||||
- Expanded test coverage for `Logger.Printf`, HTTP level mapping, and new level constructors.
|
||||
|
||||
### Documentation
|
||||
|
||||
- Improved GoDoc coverage for exported types, constructors, formatters, colors, HTTP helpers, and time layouts.
|
||||
- Documented level comparison helpers and explicit-level formatted logging.
|
||||
- Expanded inline documentation for formatter tokens and default formatter behavior.
|
||||
|
||||
### Compatibility
|
||||
|
||||
Reference in New Issue
Block a user