'use client' import { useState, useEffect } from 'react' import { motion } from 'framer-motion' import Link from 'next/link' import Navigation from '@/components/Navigation' import CreatePost from '@/components/CreatePost' import Feed from '@/components/Feed' import LandingNavbar from '@/components/LandingNavbar' import { useAuthStore } from '@/store/authStore' const features = [ { icon: ( ), title: 'GitHub Integration', description: 'Connect your GitHub account and share repositories, code snippets, and contributions as social posts.', }, { icon: ( ), title: 'Developer Community', description: 'Follow developers, join conversations, and build meaningful connections with peers worldwide.', }, { icon: ( ), title: 'Trending Projects', description: 'Discover trending repositories and the hottest open-source projects in your technology stack.', }, { icon: ( ), title: 'Developer Portfolio', description: 'Build a beautiful portfolio that showcases your projects, contributions, and coding journey.', }, { icon: ( ), title: 'Real-time Messaging', description: 'Chat with developers in real time, share code blocks, and collaborate on ideas instantly.', }, { icon: ( ), title: 'Analytics Dashboard', description: 'Track your profile views, post engagement, and repository reach with detailed analytics.', }, ] const stats = [ { value: '10K+', label: 'Developers' }, { value: '50K+', label: 'Posts Shared' }, { value: '25K+', label: 'Repos Connected' }, { value: '100+', label: 'Countries' }, ] const pricingPreview = [ { name: 'Free', price: '$0', period: 'forever', features: ['Basic profile', 'Post updates', 'Follow developers', 'Basic analytics'], highlighted: false }, { name: 'Premium', price: '$9.99', period: '/month', features: ['Verified badge', 'Advanced analytics', 'Custom themes', 'Priority support'], highlighted: true }, { name: 'Creator', price: '$19.99', period: '/month', features: ['Gold badge', 'Monetization', 'API access', 'Custom domain'], highlighted: false }, ] function LandingPage() { return (
{/* Animated Background */}
{/* Hero Section */}
Join 10,000+ developers
Where Code
Becomes{' '} Community
Showcase your projects, discover new tools, and connect with developers from around the world. The social platform built for people who build. Get Started Free Sign In
{/* Stats Section */}
{stats.map((stat, i) => (
{stat.value}
{stat.label}
))}
{/* Features Section */}

Everything Developers Need

Built from the ground up for developers who want to share their work and grow their network.

{features.map((feature, i) => (
{feature.icon}

{feature.title}

{feature.description}

))}
{/* GitHub Integration Showcase */}

Powered by{' '} GitHub

Connect your GitHub account and turn your repositories into engaging social content. Share your latest commits, showcase your projects, and let your code speak for itself.

{[ 'Auto-import repositories as shareable posts', 'Display live contribution graphs on your profile', 'Discover projects from developers you follow', 'One-click sharing of code snippets and PRs', ].map((item, i) => (
{item}
))}
{/* Mock GitHub Card */}
developer
shared a repository
awesome-project

A full-stack developer tool with real-time collaboration features

TypeScript 2.4k 183
{/* Pricing Preview */}

Simple, Transparent Pricing

Start free. Upgrade when you need more.

{pricingPreview.map((plan, i) => ( {plan.highlighted && (
MOST POPULAR
)}

{plan.name}

{plan.price} {plan.period}
    {plan.features.map((feature) => (
  • {feature}
  • ))}
{plan.name === 'Free' ? 'Get Started' : 'View Details'}
))}
Compare all features →
{/* CTA Section */}

Ready to Join?

Join thousands of developers who are already using Gitgram to showcase their work and grow their network.

Create Free Account
{/* Footer */}

Product

  • Pricing
  • Sign Up

Resources

  • Sign In

Legal

  • Terms of Service
  • Privacy Policy

Connect

© {new Date().getFullYear()} Gitgram. All rights reserved.

Built for developers, by developers.

) } function AuthenticatedHome() { const [refreshKey, setRefreshKey] = useState(0) return (
setRefreshKey(k => k + 1)} />
) } export default function HomePage() { const { isAuthenticated, isInitialized, initialize } = useAuthStore() useEffect(() => { initialize() }, [initialize]) // Show nothing while auth state is loading to avoid flash if (!isInitialized) { return (
) } if (isAuthenticated) { return } return }