UnsupportedImageWidgetBuilder typedef
UnsupportedImageWidgetBuilder =
Widget Function(BuildContext context, String url, Uint8List bytes)
Builder function to create a widget for images whose format is not supported by Flutter's standard image codec (e.g. SVG).
The bytes parameter contains the raw cached file bytes. Use a package
like flutter_svg to render them:
CachedNetworkImage(
imageUrl: 'https://example.com/image.svg',
unsupportedImageBuilder: (context, url, bytes) {
return SvgPicture.memory(bytes);
},
)
Implementation
typedef UnsupportedImageWidgetBuilder = Widget Function(
BuildContext context,
String url,
Uint8List bytes,
);