0.0.8 • Published 2 years ago

mongodjay v0.0.8

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

MongoDjay

import { Model, Field, Index, MongoModel } from 'mongodjay'

@Model({ collection: 'products', timestamps: true })
@Index({ price: 1 })
export default class Product extends MongoModel {
  @Field({ type: String, required: true, unique: true })
  title!: string

  @Field({ type: Number, min: 0.01 })
  price!: number

  createdAt!: Date
  updatedAt!: Date
}
0.0.3

3 years ago

0.0.2

3 years ago

0.0.8

2 years ago

0.0.5

3 years ago

0.0.4

3 years ago

0.0.7

2 years ago

0.0.6

3 years ago

0.0.1

4 years ago