networkImages function

dynamic networkImages(
  1. dynamic url, {
  2. dynamic shape,
  3. dynamic placeHolder,
  4. dynamic errorWidget,
  5. dynamic height,
  6. dynamic width,
})

Implementation

networkImages(url, {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,
              ),
            ),
          ),
      placeholder: (context, url) =>
          placeHolder ??
          const ShimmerWidget.circular(width: 100.0, height: 100.0),
     // errorWidget: (context, url, error) =>
  );
}