Skip to content

Instantly share code, notes, and snippets.

@chanakaDe
Created October 19, 2015 16:41
Show Gist options
  • Save chanakaDe/6c34d20664e83bfcf514 to your computer and use it in GitHub Desktop.
Save chanakaDe/6c34d20664e83bfcf514 to your computer and use it in GitHub Desktop.
var mongoose = require('mongoose');
var Schema = mongoose.Schema;
/**
* Creating Story Schema.
* @type {*|Schema}
*/
var StorySchema = new Schema({
owner: String,
title: String,
content: String,
created: {type: Date, default: Date.now}
});
module.exports = mongoose.model('Story', StorySchema);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment