简体   繁体   中英

Xamarin PCL and Microsoft.Net.Http for HttpClient is this supported on Android AND iOS?

There seem to be a lot of conflicting statements out there with regard to my question. I have a PCL project that I have added the Microsoft.Net.Http package to in order to consume a WepAPI, will this work on both my Android and iOS app? Thank you in advance.

If you choose a newer PCL profile, you don't even need to add the NuGet package and you can just use HttpClient directly.

To answer your question, yes this will work. Even with the HttpClientHandler's which Xamarin provides. It will also work with ModernHttpClient.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM