Overview
The activity feed is a real-time stream of community actions displayed on the landing page and dashboard. It showcases recent signups, project creations, and team formations to create a sense of momentum and collective progress.Activity Types
The feed tracks three types of community actions:Signups
New users join the platform
Projects
Projects are created and linked to events
Team Joins
Builders accept team invites and join projects
Visual Design
The activity feed uses animated transitions and visual hierarchy to create engaging displays:Animation Behavior
- Initial batch: First 20 activities load immediately in reverse chronological order
- Auto-scroll: New items appear every 2.4 seconds at the top
- Smooth transitions: Items fade in with blur effect and slide down
- Layout animations: Existing items smoothly reposition as new ones arrive
- Gradient fades: Top and bottom gradients create infinite scroll effect
Activity Icons
Each activity type has a distinct symbol:- Signup: → (arrow)
- Project: ◆ (diamond)
- Team join: ⬡ (hexagon)
Avatars
Activity items show user avatars with fallback behavior:- If
avatarUrlexists: Display Clerk profile image - If no avatar: Generate colored circle with initials
- Color assigned from rotating palette of 6 muted colors
Data Structure
Feed Formatting
Activities are formatted as:- Signup:
[Name] signed up - Project:
[Name] added a project: '[Project Name]' - Team join:
[Name] joined team on '[Project Name]'
Implementation
The activity feed is a React component atcomponents/activity-feed.tsx:
Key Features
Animation with Motion (Framer Motion)
Animation with Motion (Framer Motion)
Uses
motion.div with AnimatePresence for smooth enter/exit animations:Auto-scroll Timer
Auto-scroll Timer
Batch Size Management
Batch Size Management
Maintains a maximum of 20 visible items:
Public Stats Integration
The activity feed is paired with public statistics fromlib/queries.ts:
- Filters out banned and hidden profiles
- Only includes profiles registered for events
- Only includes projects linked to events
- Limits to most recent 100 activities
Landing Page Display
On the homepage (app/page.tsx), the activity feed appears in the “Where” section:
- Total signups counter
- Total projects counter
- Discord community link
Dashboard Display
Authenticated users see a similar feed on their dashboard (app/(app)/dashboard/page.tsx) showing the same community-wide activity.
Privacy Filtering
All activity queries use theisProfileVisible helper to exclude:
- Banned users don’t appear in the feed
- Hidden users (soft-deleted) don’t appear in the feed
- Only active, visible community members are showcased
Performance Considerations
The activity feed is server-rendered with static data passed to the client component. The animation timer runs entirely client-side, requiring no additional API calls.
Optimization Strategy
- Server-side query: Fetch activities once during page render
- Client-side cycling: Rotate through the static array
- No polling: No real-time updates (page refresh required for new data)
- Efficient animations: CSS transforms and opacity (GPU-accelerated)
- Fixed batch size: Memory usage capped at 20 items
Empty State
If no activities exist:Milestone Celebrations
The activity feed complements the milestone notification system inlib/milestones.ts:
- Feed shows individual actions
- Milestones celebrate community thresholds (10, 25, 50, 75, 100, 150, 200, 250, 500, 1000)
- Both create a sense of momentum and collective progress