mongoose date type

Solutions on MaxInterview for mongoose date type by the best coders in the world

showing results for - "mongoose date type"
Joan
17 Mar 2016
1const mongoose = require('mongoose');
2
3const userSchema = new mongoose.Schema({
4  name: String,
5  // `lastActiveAt` is a date
6  lastActiveAt: Date
7});
8const User = mongoose.model('User', userSchema);