Appearance
__v
_id
在 new Schema 时增加配置
//... options = { // 在 toObject() 方法转换时生效 toObject: { versionKey: false, transform: (doc, ret, options) => { delete ret._id return ret }, }, } // ...
Schema()
Document.prototype.toObject()
Transform