Skip to content
Back to projects

Project / MERN stack / Social

Community Hub

A social platform with profiles, posts and threaded discussions.

Year
2024
Role
Full-stack developer
Type
Social
Stack
MERN

Tech stack

  • React
  • Node.js
  • Express
  • MongoDB
  • Redis

01 / Overview

Overview

A community app featuring profiles, a ranked feed, threaded comments and notifications, designed to stay performant as content grows.

02 / The problem

The problem

A growing group lived in a chat that moved too fast. Good answers were buried within a day, and newcomers could not find anything.

03 / My approach

My approach

Profiles, a feed and threaded replies, in that order. The feed is ranked by recent activity, and the busiest queries are cached in Redis so the page stays quick as the content grows. Moderation tools came before launch, not after.

04 / Key features

Key features

  • Profiles with posts and activity
  • Ranked feed with infinite scroll
  • Threaded comments
  • Notifications with read state
  • Report and moderation tools
  • Search across posts and people

05 / Challenges & learnings

Challenges & learnings

  1. 01

    Infinite scroll that stays correct

    Page numbers break when new posts arrive. I switched to cursor-based pagination, so loading more never repeats or skips a post.

  2. 02

    Deep comment threads

    Loading a thread with hundreds of replies in one go was slow. Replies now load a level at a time, with a "show more" at each branch.

  3. 03

    A feed that does not repeat itself

    Caching helped speed, but stale lists confused people. Cache entries are cleared when someone posts or replies.

06 / Gallery

Gallery

Click an image to enlarge it.

Next project

Docs Search

Ask questions about a set of PDFs and get answers that point to the source page.