text: import mongoose from 'mongoose'
  const Schema = mongoose.Schema
  
  const TagSchema = new Schema({
    name: {
      type: String,
      default: ''
    },
    createdAt: {
      type: Date,
      default: Date.now
    },
    updatedAt: {
      type: Date,
      default: Date.now
    }
  })
  
  TagSchema.options.toJSON = {
    virtuals: true,
    versionKey: false,
    transform(doc, ret) {
      ret.id = ret._id
      delete ret._id
    }
  }
  
  mongoose.model('Tag', TagSchema)