Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

sqlschemify

0.1.0 • Public • Published

Build Status NPM version

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.

Install

npm i sqlschemify

DownloadsWeekly Downloads

1

Version

0.1.0

License

MIT

Last publish

Collaborators

  • avatar