mirror of
https://github.com/lovell/sharp.git
synced 2025-12-19 07:15:08 +01:00
Add support for ArrayBuffer input (#3548)
This commit is contained in:
@@ -71,6 +71,14 @@ const typedArray = function (val) {
|
||||
return false;
|
||||
};
|
||||
|
||||
/**
|
||||
* Is this value an ArrayBuffer object?
|
||||
* @private
|
||||
*/
|
||||
const arrayBuffer = function (val) {
|
||||
return val instanceof ArrayBuffer;
|
||||
};
|
||||
|
||||
/**
|
||||
* Is this value a non-empty string?
|
||||
* @private
|
||||
@@ -134,6 +142,7 @@ module.exports = {
|
||||
bool: bool,
|
||||
buffer: buffer,
|
||||
typedArray: typedArray,
|
||||
arrayBuffer: arrayBuffer,
|
||||
string: string,
|
||||
number: number,
|
||||
integer: integer,
|
||||
|
||||
Reference in New Issue
Block a user