fn-is
v1.0.0
Published
Ask for a type, returns a true/false as answer.
Downloads
7
Maintainers
Readme
fn-is
Ask for a type, returns a true / false as answer.
Install
npm install fn-is --save
If you want to use in the browser (powered by Browserify):
bower install fn-is --save
and later link in your HTML:
<script src="bower_components/fn-is/dist/fn-is.js"></script>
Usage
var is = require('fn-is');
// raw method
is(true, 'boolean'); => true
// You can use lowercase or capitalize shorcut by type method
is.boolean(true); // => true
is.Boolean(true); // => true
is.String([]); // => false
Here a list of types supported.
License
MIT © Kiko Beats