Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- const mongoose = require('mongoose');
- const Schema = mongoose.Schema;
- const practiceSchema = new Schema ({
- firstName : {
- type: String,
- required: true
- },
- lastName: {
- type: String,
- required: true
- },
- contact : [String],
- gender: {
- type:String,
- enum: ["Male", "Female"]
- }
- })
- const createModel = mongoose.model ("Newaz", practiceSchema)
- module.exports = createModel
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement