UNPKG

validate-image-type

Version:

Check the image file of a Buffer/Uint8Array that matched expected image MIME-type.

6 lines (5 loc) 275 B
/// <reference types="node" /> declare const supportedImageTypes: string[]; export type SupportedImageTypes = (typeof supportedImageTypes)[number]; export declare const imageType: (buffer: Buffer | Uint8Array | ArrayBuffer) => Promise<SupportedImageTypes | null>; export {};