cachedImgUrlWithPlaceholder static method
Implementation
static Widget cachedImgUrlWithPlaceholder({
required String url,
Widget? placeholder,
Widget? errorWidget,
BoxFit? fit,
}) {
return CachedNetworkImage(
imageUrl: url,
fit: fit,
placeholder: (context, url) =>
placeholder ??
Container(
width: 270,
height: 90,
color: Colors.white,
),
errorWidget: (context, url, error) => errorWidget ?? const Icon(Icons.error),
);
}