❝ A full-stack personal blogging platform with an authenticated Express.js API for admin post management and user commenting capabilities, powered by a reactive React.js frontend. ❞
❯ View Demo · Report Bug · Request Feature ❮
-
Implemented frontend using ReactJS and TailwindCSS with the ability to utilize RESTful API, comes with an Admin Portal where the Admin can manage posts and normal users can do comment on them.
-
Utilized react-markdown-editor as a text editor while creating posts and also used to preview them for users.
-
Implemented a RESTful API which serves as a backend for this application, built using Express.js. It follows the principles of RESTful API design:
- Resources: The API models and exposes resources such as blog posts, users, and comments as JSON data.
- HTTP Methods: It uses standard HTTP methods (GET, POST, PUT, DELETE) to perform CRUD operations on these resources.
- Routes: The API defines routes (endpoints) that map to the different resources and operations. For example,
/blog
for blog post-related operations,/user
for user management, and/comments
for handling comments. - JSON Responses: Responses from the API are sent in JSON format, making it easily consumable by the React.js frontend or any other client application.
-
The API is designed to be consumed by the React.js frontend, following the principles of separation of concerns between the client and server components of the application.
-
Managed sessions using express-session middleware, and to utilize connect-mongo to store sessions in MongoDB. which helps to retrieve and to persist sessions even after api's restart.
-
Implement user authentication using the PassportJS middleware in our Express App.
-
Secure passwords (hashing and salting) with bcryptjs package.
-
Utilized mongoose to predefining modals to operate with MongoDB database to store users, messages, and session data as collections.
-
Deployed the API to production with proper security measures like hiding keys with Environment Variables (
env
) using Dotenv package.