0.0.5 • Published 6 years ago

@waksana/naive-model v0.0.5

Weekly downloads
-
License
MIT
Repository
github
Last release
6 years ago

naive-model

simple js orm for pg

usage

const {Num, Str, Bool} = require('chkr')
const {hooks: [softDelete, timestamp, wrapLiteral, wrapCond, enableAttr, groupList]} = require('@waksana/naive-model')

const todo = {
  table: 'todo',
  hook: [softDelete, timestamp, wrapLiteral, wrapCond, enableAttr, groupList],
  field: {
    id: Num,
    name: Str,
    done: Bool,
    user_id: Num,
  }
}

module.exports = todo

TODO

  • 增加relation
0.0.5

6 years ago

0.0.4

6 years ago

0.0.3

6 years ago

0.0.1

6 years ago

0.0.0

6 years ago