hash_cached_image 0.0.2 copy "hash_cached_image: ^0.0.2" to clipboard
hash_cached_image: ^0.0.2 copied to clipboard

Streamlines image loading with blur hash placeholders, caching, error handling, and customizable widgets in Flutter apps.

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:hash_cached_image/global_parameter.dart';
import 'package:hash_cached_image/hash_cached_image.dart';

void main() {
  HashCachedImageGlobalParameter().setGlobalParameter(
    globalPlaceholderWidget: (context) {
      return const CircularProgressIndicator();
    },
    globalErrorWidget: (context, object, stackTrace) {
      return const Icon(Icons.error_rounded);
    },
  );
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  @override
  Widget build(BuildContext context) {
    return const MaterialApp(
      home: Scaffold(
        body: Center(
          child: HashCachedImage(
            imageUrl: "Image Url",
            hash: "Hash String",
          ),
        ),
      ),
    );
  }
}
12
likes
160
points
179
downloads

Publisher

unverified uploader

Weekly Downloads

Streamlines image loading with blur hash placeholders, caching, error handling, and customizable widgets in Flutter apps.

Repository (GitHub)
View/report issues

Documentation

API reference

License

GPL-3.0 (license)

Dependencies

cached_network_image, flutter, flutter_blurhash, octo_image

More

Packages that depend on hash_cached_image