This repository has been archived on 2022-03-12. You can view files and clone it, but cannot push or open issues or pull requests.
2021-04-02 02:24:13 +03:00

15 lines
853 B
TypeScript

/// <reference types="node" />
import { SharpCommandOptions, SharpGlobalOptions } from './sharp.types';
export declare function resizeBufferAsync(buffer: Buffer, sizes: number[]): Promise<Buffer[]>;
/**
* Returns `true` if a global sharp instance can be found.
* This functionality can be overridden with `process.env.EXPO_IMAGE_UTILS_NO_SHARP=1`.
*/
export declare function isAvailableAsync(): Promise<boolean>;
export declare function sharpAsync(options: SharpGlobalOptions, commands?: SharpCommandOptions[]): Promise<string[]>;
/**
* Returns the instance of `sharp` installed by the global `sharp-cli` package.
* This method will throw errors if the `sharp` instance cannot be found, these errors can be circumvented by ensuring `isAvailableAsync()` resolves to `true`.
*/
export declare function findSharpInstanceAsync(): Promise<any | null>;