1.0.1 • Published 4 years ago

@bemoje/is-function v1.0.1

Weekly downloads
1
License
MIT
Repository
github
Last release
4 years ago

@bemoje/is-function

Returns true if the argument is a function; false otherwise.

Version

Travis CI

Dependencies

Stats

Donate

Installation

npm install @bemoje/is-function
npm install --save @bemoje/is-function
npm install --save-dev @bemoje/is-function

Usage

import isFunction from '@bemoje/is-function'

isFunction(function () {})
//=> true

isFunction(class {})
//=> true

isFunction(() => {})
//=> true

isFunction()
//=> false

isFunction('a')
//=> false

isFunction(1)
//=> false

Tests

Uses Jest to test module functionality. Run tests to get coverage details.

npm run test

API

isFunction

Returns

true if the argument is a function; false otherwise.

Parameters
  • value any The value to evaluate
Returns

boolean