简体   繁体   中英

Flutter: pass downloaded image to second screen

I have a list if images download from internet. when you click on an image, it takes you to the image details screen. I want to pass the downloaded image itself to the second screen and avoid loading it again from internet. How to achieve this?

I used cached image provider plug in and it did the trick https://pub.dartlang.org/packages/cached_network_image

When another image widget uses the same URL it will load from the cache instead of downloading it again.

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