http
http copied to clipboard
feat: add fmt::Display for Version to improve usage
Hey maintainer,
I've implemented the Display trait for the Version enum to align its use with other components such as Uri and Method.
This enhancement simplifies code when working with libraries such as Axum, which exploits the http crate. Previously, converting a Version into a string (for inclusion in OpenTelemetry span in my case) required the use of the format! macro!
With this implementation, we can now call .to_string() directly on Version instances, simplifying the code base and improving readability.