You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
370 B
JavaScript

var mongoose = require('mongoose');
var Schema = mongoose.Schema;
var BookSchema = new Schema({
isbn: {
type: String,
required: true
},
title: {
type: String,
required: true
},
author: {
type: String,
required: true
},
publisher: {
type: String,
required: true
}
});
module.exports = mongoose.model('Book', BookSchema);