Skip to main content
Module

x/unitest/deps.ts>isFunction

🃏 Deno-first universal unit testing framework
Latest
function isFunction
Re-export
import { isFunction } from "https://deno.land/x/unitest@v1.0.0-beta.82/deps.ts";

Whatever argument is type of function or not

Examples

Example 1

import { isFunction } from './mod.ts'
isFunction(() => {}) // true
isFunction({}) // false

Parameters

value: unknown
  • Input any value

Returns

value is Function

The result of typeof val === 'function'