is-function
is that thing a function? Use this module to find out
Last updated 7 years ago by grncdr .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ npm install is-function 
SYNC missed versions from official npm registry.

is-function

browser support

Is that thing a function? Use this module to find out.

API

module.exports = function isFunction(fn) -> Boolean

Return true if fn is a function, otherwise false.

Why not typeof fn === 'function'

Because certain old browsers misreport the type of RegExp objects as functions.

Acknowledgements

I stole this from https://github.com/ljharb/object-keys

License

MIT

Current Tags

  • 1.0.2                                ...           latest (7 years ago)

4 Versions

  • 1.0.2                                ...           7 years ago
  • 1.0.1                                ...           13 years ago
  • 1.0.0                                ...           13 years ago
  • 0.0.0                                ...           13 years ago
Maintainers (1)
Downloads
Total 13
Today 0
This Week 0
This Month 4
Last Day 0
Last Week 0
Last Month 0
Dependencies (0)
None
Dev Dependencies (1)

© 2010 - cnpmjs.org x YWFE | Home | YWFE