Interface File

    Provides information about files and allows JavaScript in a web page to access their content.

    MDN Reference

    interface File {
        lastModified: number;
        name: string;
        size: number;
        type: string;
        webkitRelativePath: string;
        arrayBuffer(): Promise<ArrayBuffer>;
        slice(start?: number, end?: number, contentType?: string): Blob;
        stream(): ReadableStream<Uint8Array>;
        text(): Promise<string>;
    }
    Hierarchy

    Properties

    lastModified: number
    name: string
    size: number
    type: string
    webkitRelativePath: string

    Methods

    • Parameters

      • Optionalstart: number
      • Optionalend: number
      • OptionalcontentType: string

      Returns Blob