diff options
Diffstat (limited to 'models/blogPosts.js')
| -rw-r--r-- | models/blogPosts.js | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/models/blogPosts.js b/models/blogPosts.js new file mode 100644 index 0000000..6e8a0bf --- /dev/null +++ b/models/blogPosts.js @@ -0,0 +1,15 @@ +const mongoose = require('mongoose'); +const Schema = mongoose.Schema; + +const blogPostSchema = new Schema({ + postID: String, + postTitle: String, + postText: String, + postAuthor: String, + postCreationDate: Date, + postLatestEditDate: Date, + postTags: Array +}); + +const BlogPost = mongoose.model("BlogPost", blogPostSchema); +module.exports = BlogPost;
\ No newline at end of file |
