isVideoFile static method

bool isVideoFile(
  1. String filePath
)

Check if file is video

filePath - The file path Returns true if file is video

Implementation

static bool isVideoFile(String filePath) {
  const videoExtensions = ['mp4', 'avi', 'mov', 'wmv', 'flv', 'webm', 'mkv', 'm4v'];
  return hasValidExtension(filePath, videoExtensions);
}