I wana set default values for mongoose subdocument..for example lets say i have user schema
var listschema=new Schema({
name:String
})
var user=new Schema({
name:String,
email:String,
password:String,
gender:{ type:String, default:'none' },
birthdate:Date.
lists:[listschema]
})
i wana set default value for lists like [ { _id: 52a00114d9aaa04614000047, name: 'Anniversary' },
{ _id: 52a00114d9aaa04614000048, name: 'Baby Registry' },
{ _id: 52a00114d9aaa04614000049, name: 'Birthday' }]
this value should be available for every new users.whenver i update the lists with new value.this updated value should also reflects all the users on my application..Please help me .i wll be very kind enough