1.0.1 • Published 8 years ago

type-checkers v1.0.1

Weekly downloads
3
License
CC0-1.0
Repository
github
Last release
8 years ago

Type Checkers

Utility functions for checking Javascript types and primitives.

Example

JS

var assert = require( 'assert' );
var typeCheckers = require( 'type-checkers' );

var UNDEFINED;

var date = new Date( 2011, 7, 21 );

function func() {
  return true;
}

var object = {
  a: '1',
  b: '2',
  c: '3'
};

assert.equal( typeCheckers.isUndefined( UNDEFINED ), true );
assert.equal( typeCheckers.isObject( object ), true );
assert.equal( typeCheckers.isFunction( func ), true );
assert.equal( typeCheckers.isDate( date ), true );

Installation

npm install type-checkers

Contributing

We welcome your feedback and contributions. See the contribution guidelines for more details.

Additionally, you may want to consider contributing to the Capital Framework, which is the front-end pattern library used in this project.

Open source licensing info

  1. TERMS
  2. LICENSE
  3. CFPB Source Code Policy