sqlschemify
v0.1.0
Published
Produce Sequelize models from JSON Schemas
Downloads
3
Readme
sqlschemify
Produce Sequelize models from JSON Schemas.
Installation
npm install sqlschemify
Requirements
- SequelizeJS
Usage
var Sequelize = require('sequelize'),
SQLSchemify = require('sqlschemify');
var schemify = SQLSchemify({
Sequelize: Sequelize
});
var model = schemify.getModelForSchema('path/to/schema');
API
getModelForSchema(Object schema | String path) : Object model
Pass either a parsed JSON Schema, or a path to a JSON Schema file.
Returns a Sequelize Model.