1.0.3 • Published 6 years ago

kastor-models v1.0.3

Weekly downloads
1
License
MIT
Repository
gitlab
Last release
6 years ago

Kastor Models

This package provides an abstraction layer of all Kastor models shared in all endpoints and apps.

Installation

Using npm:

$ npm i --save kastor-models

Usage

Add this package to your project

{
    "dependencies": {
        "kastor-models": "kastor-models"
  }
}

## Implementation

/endpoints/community.js

const pg = require('../datasources').pg; const models = require('kastor-models');

module.exports = (app) => { app.get('/community', (req, res) => { models.Community.findAll().then(data => res.json(data)); }); };

## Enjoy

Have fun and good luck.