Open mikernet opened 3 years ago
It appears that adding this Blazor WASM package to the Uno WASM project and calling this method works:
Should there be a different mechanism for Uno WASM to enable this or is this the approach that is recommended? It's a bit annoying to lose the ability to use all the HttpClient
methods, instead only using ones that accept HttpRequestMessage
and then having to call that extension method on every request message.
Either way, I think it would be good to document this somehow as finding this solution was rather difficult and I wasn't sure if it was going to work for Uno or if it was Blazor specific.
Current behavior
The underlying
fetch
call does not setcredentials: 'include'
so authentication cookies aren't sent for web service requests.Expected behavior
Match
HttpClient
behavior in UWP and send authentication cookies or provide a mechanism to include credentials.Workaround
Not sure - I searched and did not find any way to set the fetch request to include credentials in Uno.
Environment
Nuget Package:
Nuget Package Version(s): 3.5.0
Affected platform(s):