@breautek/storm
    Preparing search index...

    Interface File

    interface File {
        filepath: string;
        hash?: string;
        hashAlgorithm: false | "sha1" | "md5" | "sha256";
        mimetype: string;
        mtime?: Date;
        newFilename: string;
        originalFilename: string;
        size: number;
        toJSON(): formidable.FileJSON;
        toString(): string;
    }
    Index

    Properties

    filepath: string

    The path this file is being written to. You can modify this in the 'fileBegin' event in case you are unhappy with the way formidable generates a temporary path for your files.

    hash?: string

    If options.hashAlgorithm calculation was set, you can read the hex digest out of this var (at the end it will be a string).

    hashAlgorithm: false | "sha1" | "md5" | "sha256"
    mimetype: string

    The mime type of this file, according to the uploading client.

    mtime?: Date

    A Date object (or null) containing the time this file was last written to. Mostly here for compatibility with the W3C File API Draft.

    newFilename: string

    Calculated based on options provided

    originalFilename: string

    The name this file had according to the uploading client.

    size: number

    The size of the uploaded file in bytes. If the file is still being uploaded (see 'fileBegin' event), this property says how many bytes of the file have been written to disk yet.

    Methods

    • Returns string