All Projects → Baseflow → Flutter_cached_network_image

Baseflow / Flutter_cached_network_image

Licence: mit
Download, cache and show images in a flutter app

Programming Languages

dart
5743 projects
C++
36643 projects - #6 most used programming language
CMake
9771 projects
ruby
36898 projects - #4 most used programming language
HTML
75241 projects

Projects that are alternatives of or similar to Flutter cached network image

Maplebacon
🍁🥓 Lightweight and fast Swift library for image downloading, caching and transformations
Stars: ✭ 322 (-83.26%)
Mutual labels:  caching, image
Hrconvert2
A self-hosted, drag-and-drop, & nosql file conversion server that supports 62x file formats.
Stars: ✭ 132 (-93.14%)
Mutual labels:  image
Winmerge
WinMerge is an Open Source differencing and merging tool for Windows. WinMerge can compare both folders and files, presenting differences in a visual text format that is easy to understand and handle.
Stars: ✭ 2,358 (+22.62%)
Mutual labels:  image
Collage maker
Picture collage maker in Python
Stars: ✭ 131 (-93.19%)
Mutual labels:  image
Bbwebimage
A high performance Swift library for downloading, caching and editing web images asynchronously.
Stars: ✭ 128 (-93.34%)
Mutual labels:  image
Zoomy
Adds seamless scrollView and instagram like zooming to UIImageViews in any view hierarchy.
Stars: ✭ 130 (-93.24%)
Mutual labels:  image
Lerc
Limited Error Raster Compression
Stars: ✭ 126 (-93.45%)
Mutual labels:  image
Releases
WLAN Pi Release Repository
Stars: ✭ 135 (-92.98%)
Mutual labels:  image
Image Resizer
Resize/Crop/Rotate/Pad images in Clojure without any native install. Oh and do it Fast.
Stars: ✭ 133 (-93.08%)
Mutual labels:  image
Laravel Model Caching
Eloquent model-caching made easy.
Stars: ✭ 1,829 (-4.89%)
Mutual labels:  caching
Imagehash
🌄 Perceptual image hashing for PHP
Stars: ✭ 1,744 (-9.31%)
Mutual labels:  image
Data Prefetch Link
Extends next.js <Link> to allow invoking getInitialProps when prefetching a page
Stars: ✭ 128 (-93.34%)
Mutual labels:  caching
Kjemitterview
粒子效果、扩展、好用的工具等等,Button图文混排、点击事件封装、扩大点击域、点赞粒子效果,手势封装、圆角渐变、倒影、内阴影处理、Xib属性、识别网址超链接,图片加工处理、对花铺贴效果、滤镜渲染、泛洪算法,_KJMacros常用宏定义,Label富文本,自定义动画选中控件,Alert控件,数组和字典防崩处理,数组算法处理等等等
Stars: ✭ 133 (-93.08%)
Mutual labels:  image
Mergi
go library for image programming (merge, crop, resize, watermark, animate, ease, transit)
Stars: ✭ 127 (-93.4%)
Mutual labels:  image
Image Focus
A dependency free utility for cropping images based on a focus point ~2.13kB gzipped
Stars: ✭ 134 (-93.03%)
Mutual labels:  image
Stfalconimageviewer
A simple and customizable Android full-screen image viewer with shared image transition support, "pinch to zoom" and "swipe to dismiss" gestures
Stars: ✭ 1,734 (-9.83%)
Mutual labels:  image
Image Promise
🎑🤞 Load one or more images, return a promise. Tiny, browser-only, no dependencies.
Stars: ✭ 129 (-93.29%)
Mutual labels:  image
Fabric Photo
基于canvas的前端图片编辑器
Stars: ✭ 132 (-93.14%)
Mutual labels:  image
Imgdupes
Finding and deleting near-duplicate images based on perceptual hash.
Stars: ✭ 135 (-92.98%)
Mutual labels:  image
Vifmimg
Image previews using Überzug for Vifm (vi file manager)
Stars: ✭ 135 (-92.98%)
Mutual labels:  image

Cached network image

pub package codecov Build Status

A flutter library to show images from the internet and keep them in the cache directory.

Sponsors


Try the Flutter Chat Tutorial 💬

How to use

The CachedNetworkImage can be used directly or through the ImageProvider. Both the CachedNetworkImage as CachedNetworkImageProvider have minimal support for web. It currently doesn't include caching.

With a placeholder:

CachedNetworkImage(
        imageUrl: "http://via.placeholder.com/350x150",
        placeholder: (context, url) => CircularProgressIndicator(),
        errorWidget: (context, url, error) => Icon(Icons.error),
     ),

Or with a progress indicator:

CachedNetworkImage(
       imageUrl: "http://via.placeholder.com/350x150",
       progressIndicatorBuilder: (context, url, downloadProgress) => 
               CircularProgressIndicator(value: downloadProgress.progress),
       errorWidget: (context, url, error) => Icon(Icons.error),
    ),
Image(image: CachedNetworkImageProvider(url))

When you want to have both the placeholder functionality and want to get the imageprovider to use in another widget you can provide an imageBuilder:

CachedNetworkImage(
  imageUrl: "http://via.placeholder.com/200x150",
  imageBuilder: (context, imageProvider) => Container(
    decoration: BoxDecoration(
      image: DecorationImage(
          image: imageProvider,
          fit: BoxFit.cover,
          colorFilter:
              ColorFilter.mode(Colors.red, BlendMode.colorBurn)),
    ),
  ),
  placeholder: (context, url) => CircularProgressIndicator(),
  errorWidget: (context, url, error) => Icon(Icons.error),
),

How it works

The cached network images stores and retrieves files using the flutter_cache_manager.

FAQ

My app crashes when the image loading failed. (I know, this is not really a question.)

Does it really crash though? The debugger might pause, as the Dart VM doesn't recognize it as a caught exception; the console might print errors; even your crash reporting tool might report it (I know, that really sucks). However, does it really crash? Probably everything is just running fine. If you really get an app crashes you are fine to report an issue, but do that with a small example so we can reproduce that crash.

See for example this or this answer on previous posted issues.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].