networkImages static method
dynamic
networkImages(
- dynamic url,
- dynamic errorImagePath, {
- dynamic shape,
- dynamic placeHolder,
- dynamic errorWidget,
- dynamic height,
- dynamic width,
Implementation
static networkImages(url,errorImagePath,{shape, placeHolder, errorWidget, height, width}) {
return CachedNetworkImage(
imageUrl: url,
imageBuilder: (context, imageProvider) => Container(
height: height ?? 100,
width: width ?? 100,
decoration: BoxDecoration(
shape: shape ?? BoxShape.circle,
image: DecorationImage(
image: imageProvider,
fit: BoxFit.cover,
),
),
),
errorWidget:(context,errorImagePath,_)=> assetImage(image: errorImagePath),
placeholder: (context, url) =>
placeHolder ??
const ShimmerWidget.circular(width: 100.0, height: 100.0),
// errorWidget: (context, url, error) =>
);
}