npm.io
0.1.0 • Published 11 years ago

ball

Licence
MIT
Version
0.1.0
Deps
3
Vulns
1
Weekly
0

Ball

Simple MongoDB ODM

Usage

const {Ball} = require('ball');

let db = new Ball('mongodb://localhost/db');

class User {
  getFullName() {
    return `${this.firstName} ${this.secondName}`;
  }
}

db.find({}).map((user) => {
  console.log({
    fullName: user.getFullName()
  });
}).catch((err) => {
  // error handling
})

License

MIT