-
-
Notifications
You must be signed in to change notification settings - Fork 403
Description
Current behavior 😯
Currently, the default behavior of the gix::Url is to seralize as a sort of json object of it's components. Just curious if there is actually some conscious reason for this, or perhaps it is just something that got overlooked, in which case, I can maybe submit a patch for it to rectify.
Expected behavior 🤔
I don't think this is what anyone whould expect nor desire from a type representing a URL.
I am able to rectify this in my own code by using #[serde(serialize_with // ..., etc to change the behavior, but it is a bit tedious when using the Url in multiple places. I think the most intuitive approach is to seralize and deserialize to a string representation of a URL, since that is primarily what a URL is.
Git behavior
not strictly relevant
Steps to reproduce 🕹
just serialize a gix::Url with serde and observe the output.