- Node.js
- Express.js
- JWT
- Sequelize
- AWS EB
- AWS S3
- Naming conventions
- Readability of the code
- Your file structure
- Error handling
Reply back to the email with an open github repository.
You work in an agile environment where your manager keeps on coming up with new requirements. The requirements are listed below, you have to change your code or your model and create migration files requirement by requirement. Create a branch and README.md(explaingin your approach to solve it) for each requirement listed below. Screenshots of the api call results are appreciated in README.md but not required.
- Create express.js app and use postgres sql as database.
- Make routes where user can register itself. Required fields of user are name, email and password.
- User can login with its email and password and gets a JWT token.
- Logged in users can create a post. Post has 3 attribues title, description and a photo.
Your manager next week talks to the client and gives you necessary changes to be made this week.
- A post will have an attribute when it was created.
- Post returning api will calculate the time difference like 2s ago, 10d ago, 4w ago, 8m ago and 1yr ago.
- A post can have multiple photos but atmost 5.
- A post can be editied.
- A post can have multiple comments. Comments will show the user who commented and the comment.
- Need to add pagination in the post and in the comments of the post.
- User have the option to create their username. Update the user model.