Skip to content

postgrelize / CreatedAt

Variable: CreatedAt ​

const CreatedAt: ModelPropertyDecorator

Defined in: src/decorators/timestamp-decorators.ts:15

Names the attribute that holds the creation time (createdAt: '<attribute>').

Example ​

ts
class User extends Model {
  @CreatedAt
  creationDate!: Date;
}

Released under the MIT License.