Files
30-seconds-of-code/node_modules/graphql-compose/lib/utils/is.js
2019-08-20 15:52:05 +02:00

26 lines
550 B
JavaScript

"use strict";
Object.defineProperty(exports, "__esModule", {
value: true
});
exports.isString = isString;
exports.isObject = isObject;
exports.isFunction = isFunction;
function isString(value)
/* : boolean %checks */
{
return typeof value === 'string';
}
function isObject(value)
/* : boolean %checks */
{
return typeof value === 'object' && !Array.isArray(value) && value !== null;
}
function isFunction(value)
/* : boolean %checks */
{
return !!(value && value.constructor && value.call && typeof value === 'function' && value.apply);
}