mirror of https://github.com/jkjoy/sunpeiwen.git
8 lines
267 B
JavaScript
8 lines
267 B
JavaScript
|
import isFunction from "./isFunction.js";
|
||
|
export const isFileLike = (value) => Boolean(value
|
||
|
&& typeof value === "object"
|
||
|
&& isFunction(value.constructor)
|
||
|
&& value[Symbol.toStringTag] === "File"
|
||
|
&& isFunction(value.stream)
|
||
|
&& value.name != null);
|