31ec6f9c5fd05a936da790d82ffea87cdec0ef8d
[aai/esr-gui.git] /
1 export function objectOrFunction(x) {
2   return typeof x === 'function' || (typeof x === 'object' && x !== null);
3 }
4
5 export function isFunction(x) {
6   return typeof x === 'function';
7 }
8
9 export function isMaybeThenable(x) {
10   return typeof x === 'object' && x !== null;
11 }
12
13 var _isArray;
14 if (!Array.isArray) {
15   _isArray = function (x) {
16     return Object.prototype.toString.call(x) === '[object Array]';
17   };
18 } else {
19   _isArray = Array.isArray;
20 }
21
22 export var isArray = _isArray;