nodetype

0.0.6 • Public • Published

NODE-TYPE

Installation

npm install nodetype

Usage

// nodetype.check(type, value, convert);
nodetype.check('Boolean', 'True', true);


function MyObject () {
	this.hello = 'world';
	this.world = 'hello';
}

nodetype.set('MyObject', function (val) {
	return (val.hello || undefined) === 'world' && (val.world || undefined) === 'hello';
});

var myobj = new MyObject;

console.log(nodetype.check('MyObject', myobj));

Dependencies (0)

    Dev Dependencies (0)

      Package Sidebar

      Install

      npm i nodetype

      Weekly Downloads

      7

      Version

      0.0.6

      License

      BSD

      Last publish

      Collaborators

      • poying