Skip to content

modella/timestamps

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

12 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

modella-timestamps

Adds createdAt and updatedAt fields to the given model using the fields specified and updates them autoamtically.

Usage Example

var modella    = require('modella');
var timestamps = require('modella-timestamps');

var User = modella('User');

// Use the default createdAt and updatedAt field names:
User.use(timestamps);

// Specify custom field names:
User.use(timestamps('born_at', 'changed_at'));

About

CreatedAt and UpdatedAt for Modella

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •