Skip to main content
isFunction - node__util.d.ts - Node documentation
function isFunction

Usage in Deno

```typescript import { isFunction } from "node:node__util.d.ts"; ```
isFunction(object: unknown): boolean
Deprecated
Since v4.0.0 - Use `typeof value === 'function'` instead.
Returns `true` if the given `object` is a `Function`. Otherwise, returns `false`. ```js import util from 'node:util'; function Foo() {} const Bar = () => {}; util.isFunction({}); // Returns: false util.isFunction(Foo); // Returns: true util.isFunction(Bar); // Returns: true ```

Parameters

object: unknown

Return Type

boolean