-
Notifications
You must be signed in to change notification settings - Fork 16
Open
Description
Create a news schema in mongoose.
Parameters to be defined in the news schema -
- Title - string
- Content - string
- type - string
- abstract - string
- photos - this will be an array
- timestamp. - object
For timestamp follow the below mentioned pseudo object.
timestamp: {
published_at: timestamp,
created_at: timestamp,
updated_at: timestamp
}
type signifies to which category the particular news belongs to -
Some types for example -
- India news
- geopolitical news
- entertainment news
- political news
- cricket news
Cover all the type of news and create an enum check on them as well.
abstract is similar to the content but in very short format.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels