Unleash awesomeness. Private packages, team management tools, and powerful integrations. Get started with npm Orgs »

schema-mapper-differ

0.4.2 • Public • Published

schema-mapper-differ

Get a list of Changes by comparing 2 Projects.

Build status Docs status Code Climate Dependencies License

Installation

npm install --save schema-mapper-differ

Usage

var differ = require('schema-mapper-differ');
 
var oldProjects = {};
var projects = {
  '0': {
    name: 'demo',
    version: 0,
    schemas: {
      '1': {
        name: 'users',
        primary: '1',
        columns: {
          '1': {
            name: 'id',
            type: 'uuid'
          }
        }
      }
    }
  }
};
 
var changes = differ.diffProjects(oldProjects, projects);
console.log(changes);
[
  {
    change: 'project.create',
    projectId: '0',
    project: {
      name: 'demo',
      version: 0,
      schemas: {
        '1': {
          name: 'users',
          primary: '1',
          columns: {
            '1': {
              name: 'id',
              type: 'uuid'
            }
          }
        }
      }
    }
  }
]

API docs

API Docs

Licence

MIT

Keywords

none

install

npm i schema-mapper-differ

Downloadsweekly downloads

5

version

0.4.2

license

MIT

homepage

github.com

repository

Gitgithub

last publish

collaborators

  • avatar
Report a vulnerability