isSvgAsset function

bool isSvgAsset(
  1. String? value
)

Returns true when value points to a Flutter asset SVG.

Two conditions must hold: the value ends with .svg (case-insensitive) and it is not a remote (http/https) URL.

Implementation

bool isSvgAsset(String? value) {
  final lower = value?.trim().toLowerCase();
  if (lower == null) return false;
  return lower.endsWith('.svg') && !lower.startsWith('http');
}