📜  猫鼬模式 - Javascript 代码示例

📅  最后修改于: 2022-03-11 15:02:20.400000             🧑  作者: Mango

代码示例3
// Define schema
var Schema = mongoose.Schema;

var SomeModelSchema = new Schema({
  a_string: String,
  a_date: Date
});

// Compile model from schema
var SomeModel = mongoose.model('SomeModel', SomeModelSchema );