1.0.3 • Published 9 years ago

easy-implements v1.0.3

Weekly downloads
-
License
ISC
Repository
-
Last release
9 years ago

Dead simple interface / data verification

Alpha version, subject to random change without cause or warning.

First define your interface in seperate module:

interface/Person.js

var PersonInterface = { name: 'Person', required: { first_name: 'string', last_name: 'age', } optional: { age: 'number', } }

var PersonInterface = require('./interface/Person.js');

var Implements = require('easy-implements');

Implements(Personinterface, myObj); //Throws error if no bueno

1.0.3

9 years ago

1.0.2

9 years ago

1.0.1

9 years ago

1.0.0

9 years ago