I see we use FFImageLoading
like below
var cachedImage = new CachedImage() {
HorizontalOptions = LayoutOptions.Center,
VerticalOptions = LayoutOptions.Center,
WidthRequest = 300,
HeightRequest = 300,
...
Source = <url or asset or resource location>
};
or in XAML:
<ffimageloading:CachedImage
HorizontalOptions="Center" VerticalOptions="Center"
WidthRequest="300" HeightRequest="300"
DownsampleToViewSize="true"
Source = "<url or asset or resource location>>
</ffimageloading:CachedImage>
, so, I replaced all instances of Image
in my UWP project and ImageView
in my Android project with CachedImage
.
But after reading through FFImageLoading documentation, I also see lots of
cases where images are loaded using ImageService
. For example:
ImageService.Instance.LoadUrl(urlToImage).Into(_imageView);
ImageService.Instance.LoadCompiledResource(nameOfResource).Into(_imageView);
...
What is the difference between these two ways?
Why would I use one over the other?