mongo-essential

1.0.4 • Public • Published

mongo-essential

Mongo plugin for node-essential.

Getting started

npm i --save mongo-essential
const { BaseDB, EntityBase } = require("mongo-essential");

class UserModel extends EntityBase {
  constructor() {
    super();
    this.id = "";
    this.name = "";
  }
}

class UserTableManager extends BaseDB {   
  constructor(injection) {
    super("user", { injection });
  }
  
  get entityType() {
    return UserModel;
  }
}

Readme

Keywords

none

Package Sidebar

Install

npm i mongo-essential

Weekly Downloads

0

Version

1.0.4

License

MIT

Unpacked Size

8.7 kB

Total Files

7

Last publish

Collaborators

  • lcnvdl