fast_cached_network_image
1.3.3+5, released 2 years ago by an unverified publisher
Widget to display network images with caching, loading indicators and fade transitions.
What it does
FastCachedNetworkImage downloads images, stores them in a Hive cache, and serves them from local storage on subsequent loads. It provides customizable loading and error widgets, progress reporting, and fade‑in animations.
AI-written summary of version 1.3.3+5, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need offline access to frequently used images
- You want built‑in progress indicators or custom loaders
- You target multiple platforms including web and desktop
Skip it when
- App size must be minimal and you can’t afford extra dependencies
- You need fine‑grained cache policies beyond simple TTL
- You require advanced image manipulation or transformations
Strengths
- Simple API with built‑in caching
- Supports progress, error handling and fade animations
- Works on mobile, web and desktop out of the box
Weaknesses
- Relies on Hive for storage, adding another dependency
- Cache management is limited to clear‑all or per‑image deletion
- Large images may still consume significant disk space
Setup
- Kind
- Flutter widgets
- Effort
- Medium
- Code generation
- No
- Direct dependencies
- 3
Call FastCachedImageConfig.init() (optionally with subDir and clearCacheAfter) before runApp; ensure hive_ce_flutter is added; no special permissions required.
import 'package:fast_cached_network_image/fast_cached_network_image.dart';
import 'package:flutter/material.dart';
void main() async {
WidgetsFlutterBinding.ensureInitialized();
await FastCachedImageConfig.init();
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
@override
Widget build(BuildContext context) => MaterialApp(
home: Scaffold(
body: Center(
child: FastCachedImage(
url: 'https://example.com/image.jpg',
fit: BoxFit.cover,
),
),
),
);
}Alternatives
Packages that do the same job and could replace fast_cached_network_image.
- cached_network_image
Mature package with extensive caching options and fewer dependencies
91Compare - octo_image
Provides placeholders, error widgets and fade effects with a flexible API
94Compare - photo_view
Adds pinch‑to‑zoom and pan capabilities on top of cached images
50Compare
Works with
Packages commonly used together with fast_cached_network_image: ones it builds on, ones built on it, and its own family.
- uuidfast_cached_network_image depends on itGenerates and parses RFC‑4122/9562 UUIDs (v1‑v8) for Dart.
- diofast_cached_network_image depends on itA powerful HTTP networking package for Dart and Flutter with interceptors and request cancellation.
- hive_ce_flutterfast_cached_network_image depends on itFlutter extension for Hive database initialization and path management