wadofgum-json-schema 
A validation mixin for wadofgum using z-schema.
Usage
After extending your model with this mixin, instances of your class will have a validate
method. This method returns a promise that resolves when validation is complete or rejects if validation fails.
Simply provide a json schema for validation and then assign it to the static schema
property on your class.
const Wadofgum = require('wadofgum');
const Validation = require('wadofgum-json-schema');
class Model extends Wadofgum.mixin(Validation) {};
Model.schema = {
type: 'object',
properties: {
name: {
type: 'string'
},
age: {
type: 'integer'
},
dateOfBirth: {
type: 'string',
format: 'date'
}
}
};
let model = new Model({ name: 'test', age: '45', dateOfBirth: '1975-10-01'});
model.validate().then(function () {
model.name;
model.age;
model.dateOfBirth;
});