Closed MihaMarkic closed 11 months ago
For Host, the short answer is no. Flurl leverages System.Uri for some aspects of its parsing, and that class normalizes the passed string to its canonical form, which includes lower-casing the scheme and host.
You can re-open this as a feature request if you want. I just wanted to explain how it works today. Admittedly, it was never intentional behavior and Flurl generally has the philosophy of don't mess with the original string. So I would entertain it if there are legitimate use cases.
Is there a way to preserve letter casing with Flurl's URL parsing? Currently it would always lowercase Host.
Input: var url = Url.Parse("https://SomeThing.com/Path")
Output using url.ToString()
Actual: https://something.com/Path
Expected: https://SomeThing.com/Path
Related stack overflow question.