All files / src/preds isFn.ts

100% Statements 4/4
100% Branches 3/3
100% Functions 1/1
100% Lines 4/4
1 2 3 4 5 6 7 8 9  15x   12658x   12658x     15x
export default function isFunction( x ) {
  var getType = {};
  // (x || false) guarantees returning of boolean type
  return ( x || false ) &&
   [ '[object Function]', '[object GeneratorFunction]' ].indexOf(
    getType.toString.call( x )
   ) >= 0;
}