flutter_advanced_networkimage 0.2.11 copy "flutter_advanced_networkimage: ^0.2.11" to clipboard
flutter_advanced_networkimage: ^0.2.11 copied to clipboard

discontinued
outdated

An advanced image provider for flutter.

Flutter Advanced Network Imageprovider #

pub package

An advanced image provider provides caching and retrying for flutter app. Now with zoomable widget and transition to image widget.

Getting Started #

Installation #

Add this to your pubspec.yaml (or create it):

dependencies:
  flutter_advanced_networkimage: any

Then run the flutter tooling:

flutter packages get

Example #

// using image provider
Image(
  image: AdvancedNetworkImage(url, header: header, useDiskCache: true),
  fit: BoxFit.cover,
)
// get the disk cache folder size
int folderSize = await getDiskCachedImagesSize();
// clean the disk cache
bool isSucceed = await clearDiskCachedImages();
// using zooming widget & transitiontoimage widget
ZoomableWidget(
  minScale: 0.3,
  maxScale: 2.0,
  // default factor is 1.0, use 0.0 to disable boundary
  panClampFactor: 0.8,
  child: Container(
    child: TransitionToImage(
      AdvancedNetworkImage(url, timeoutDuration: Duration(minutes: 1)),
      // This is the default placeholder widget at loading status,
      // you can write your own widget with CustomPainter.
      placeholder: CircularProgressIndicator(),
      // This is default duration
      duration: Duration(milliseconds: 300),
      fallbackWidget: DecoratedBox(...),
    ),
  ),
)
// using reload feature(you can use a `GestureDetector`
// widget to wrap `TransitionToImage` widget)
TransitionToImage imageWidget = TransitionToImage(
  AdvancedNetworkImage(url),
  useReload: true,
  reloadWidget: Icon(Icons.replay),
);
ZoomableWidget(
  minScale: 0.3,
  maxScale: 2.0,
  child: imageWidget,
  tapCallback: imageWidget.reloadImage,
),

Details in example/ folder.

demo gif

122
likes
0
pub points
86%
popularity

Publisher

unverified uploader

An advanced image provider for flutter.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

crypto, flutter, http, path, path_provider, quiver

More

Packages that depend on flutter_advanced_networkimage