『 based_local_first_image - Based Local First Image! 』
Latest update: 2023-10-03 15:55:26
📚 Introduction
Welcome to the world of local-first web development.
📦 How to use
- Follow Installing to add
based_local_first_image
to yourpubspec.yaml
Image(
image: BasedLocalFirstImage(
filename: '$index.png',
localDirectory: path.join(appSupport.path, 'image'),
remoteUrl: 'https://avatars.githubusercontent.com/u/$index?v=4',
),
errorBuilder: (context, error, stackTrace) => const Placeholder(),
loadingBuilder: (context, child, loadingProgress) {
if (loadingProgress == null) {
return child;
}
return CircularProgressIndicator(
value: loadingProgress.expectedTotalBytes != null
? loadingProgress.cumulativeBytesLoaded /
loadingProgress.expectedTotalBytes!
: null,
);
},
),
🧑💻 Contributor
🔦 Declaration
This project is licensed under the terms of the MIT
license. See LICENSE for more details