Checks if value is classified as a Function object.
value
Function
The value to check.
Returns true if value is a function, else false.
true
false
5.5.0
isFunction(class Any{})// => trueisFunction(() => {})// => trueisFunction(async () => {})// => trueisFunction(function * Any() {})// => trueisFunction(Math.round)// => trueisFunction(/abc/)// => false Copy
isFunction(class Any{})// => trueisFunction(() => {})// => trueisFunction(async () => {})// => trueisFunction(function * Any() {})// => trueisFunction(Math.round)// => trueisFunction(/abc/)// => false
Checks if
value
is classified as aFunction
object.