1.1.0 • Published 9 years ago

fn-typeof v1.1.0

Weekly downloads
3
License
MIT
Repository
github
Last release
9 years ago

fn-typeof

Last version Build Status Dependency status Dev Dependencies Status NPM Status Gittip

Get the type of something. Seriously.

Install

npm install fn-typeof --save

If you want to use in the browser (powered by Browserify):

bower install fn-typeof --save

and later link in your HTML:

<script src="bower_components/fn-typeof/dist/fn-typeof.js"></script>

Usage

var typeOf = require('fn-typeof');

console.log(typeOf({})) // => 'object'
console.log(typeOf([])) // => 'array'

console.log(typeOf.types)
// => [
// 'array',
// 'boolean',
// 'date',
// 'function',
// 'number',
// 'object',
// 'regexp',
// 'string'
// ];

License

MIT © Kiko Beats