0.0.32 • Published 6 months ago

@types/s3-uploader v0.0.32

Weekly downloads
31
License
MIT
Repository
github
Last release
6 months ago

Installation

npm install --save @types/s3-uploader

Summary

This package contains type definitions for s3-uploader (https://www.npmjs.com/package/s3-uploader).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/s3-uploader.

index.d.ts

// Type definitions for s3-uploader
// Project: https://www.npmjs.com/package/s3-uploader
// Definitions by: COLSA Corporation <http://www.colsa.com/>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped

//NOTE: Does require GM (https://github.com/aheckmann/gm) thus requires GraphicsMagick (http://www.graphicsmagick.org/) or ImageMagick (http://www.imagemagick.org/)

export = Upload;

declare namespace Upload {
    interface S3UploaderVersion {
        original?: boolean | undefined;
        suffix?: string | undefined;
        quality?: number | undefined;
        maxWidth?: number | undefined;
        maxHeight?: number | undefined;
    }

    interface S3UploaderOptions {
        awsAccessKeyId?: string | undefined;
        awsSecretAccessKey?: string | undefined;
        awsBucketRegion?: string | undefined;
        awsBucketPath?: string | undefined;
        awsBucketAcl?: string | undefined;
        awsMaxRetries?: number | undefined;
        awsHttpTimeout?: number | undefined;
        resizeQuality?: number | undefined;
        returnExif?: boolean | undefined;
        tmpDir?: string | undefined;
        workers?: number | undefined;
        url?: string | undefined;
        versions?: S3UploaderVersion[] | undefined;
    }

    interface Meta {
        format: string;
        fileSize: string;
        imageSize: imageSize;
        orientation: string;
        colorSpace: string;
        compression: string;
        quallity: string;
    }

    interface imageSize {
        height: number;
        width: number;
    }

    interface image {
        etag: string;
        format: string;
        height: number;
        original: boolean;
        path: string;
        size: string;
        src: string;
        url: string;
        width: number;
    }
}

declare class Upload {
    public constructor(awsBucketName: string, opts: Upload.S3UploaderOptions);

    public upload(src: string, opts?: Upload.S3UploaderOptions, cb?: (err: string, images: Upload.image[], meta: Upload.Meta) => void): void;
}

Additional Details

  • Last updated: Tue, 06 Jul 2021 16:34:10 GMT
  • Dependencies: none
  • Global values: none

Credits

These definitions were written by COLSA Corporation.

0.0.30

8 months ago

0.0.31

7 months ago

0.0.32

6 months ago

0.0.29

3 years ago

0.0.28

7 years ago

0.0.27

8 years ago

0.0.26

8 years ago

0.0.25-alpha

8 years ago

0.0.24-alpha

8 years ago

0.0.23-alpha

8 years ago

0.0.22-alpha

8 years ago

0.0.21-alpha

8 years ago

0.0.20-alpha

8 years ago

0.0.19-alpha

8 years ago

0.0.14-alpha

8 years ago

0.0.13-alpha

8 years ago