Created
October 7, 2017 12:26
-
-
Save odahcam/5080d6c8c1dcc54ee04f3cf42695cbc3 to your computer and use it in GitHub Desktop.
Checks if a value is a fucntion.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function isFunction(functionToCheck) { | |
var getType = {}; | |
return functionToCheck && getType.toString.call(functionToCheck) === '[object Function]'; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment