Created
August 11, 2018 01:35
-
-
Save Turbiani/48f9a74d2434d0323f5edde59709954e to your computer and use it in GitHub Desktop.
Post entity
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const uuid = require('uuid/v4'); | |
const Entity = require('./EntityBase'); | |
class Post extends Entity { | |
constructor(title, description, postedBy) { | |
super(uuid()); | |
this.title = title; | |
this.description = description; | |
this.postedBy = postedBy; | |
} | |
} | |
module.exports = Post; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment