Baseflow / Baseflow/flutter_cached_network_image
CachedNetworkImage is not loading images on iOS app
- Dominant language
- Dart
- Stars
- 2.6k
- Forks
- 731
- Avg merge
- 3d 9h
- Merged PRs (30d)
- 1
Description
### Overview
I am adding flutter as a module into my existing native iOS and Android application. The issue I am facing is that the image is not loading on iOS. Only the placeholder Image is displaying and not even errorWidget is getting displayed. The same codebase works fine for Android native app.
I am using the below version of the library:
``` cached_network_image: ^3.2.1```
### Findings
I saw that the library is using flutter_chache_manager internally which internally uses the sqlite plugin. Since our app is also using the sqlite db and AwesomeCache library for iOS ,could it be an issue due to some conflict? This assumption is based on the fact that I created a new sample app in iOS and integrated the same flutter module into that. There it's working fine. The images are loading properly along with the placeholders.
### Other things tried
I have tried setting the cacheKey and also a custom cacheManager with a unique key to avoid any conflicts but still no luck.
I replaced the CachedNetworkImage with Image.network and its working fine.
### Debugging
Below is my code:
```dart
CachedNetworkImage(
imageUrl: item["image"] as String, //debugger stops here
imageBuilder: (context, imageProvider) => Container(
decoration: BoxDecoration( //debugger never comes here
image: DecorationImage(
image: imageProvider,
fit: BoxFit.fill,
),
),
),
placeholder: (context, url) => //debugger stops here
Image.asset('assets/images/home.png'),
errorWidget: (context, url, error) =>
Image.asset('assets/images/img.png'),
)
```
Could anyone please help me with this pointing out the places within the library where I could debug the image loading code. Also I tried using Charles Proxy and couldn't find any network call going for those image URLs.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.