Toolbox-XToolbox-X
GuardsDOM Guards

Check File Array

Checks if a value is an array of native File objects.

isFileArray

Checks if a value is an array of native File objects.

Function Signature

isFileArray(value: unknown): value is File[] | Blob[]

Validation Rules

  • Must be non-empty array
  • Every element must be File instance

Example

const files = [new File([], 'test.txt')];
isFileArray(files); // true

Last updated: Tue, May 26, 2026 04:14:18PM (UTC)

On this page