UNPKG

isomorphic-image-hash

Version:

A dhash library that works in both browsers and Node.js.

11 lines (10 loc) 400 B
import { dhashFromImageData } from './hash/dhash'; export { distance } from './utils/distance'; export { dhashFromImageData }; export interface ImageDataLike { width: number; height: number; data: Uint8Array | Uint8ClampedArray; } export declare const getImageData: (path: string) => Promise<ImageDataLike>; export declare const dhash: (image: string | ImageDataLike) => Promise<string>;