A comprehensive platform for discovering, organizing, and sharing AI tools and developer resources
Features β’ Tech Stack β’ Setup Guide β’ Deployment
| Feature | Description |
|---|---|
| π Authentication | Secure email/password signup, login, and password reset |
| π Submit Links | Authenticated users can submit AI tools and websites |
| π Browse & Search | View all active links with powerful full-text search |
| π·οΈ Filter by Category | Multi-select category filtering with "match all" or "match any" modes |
| π€ User Profile | Manage personal profile information |
| β‘ Real-time Updates | See new links instantly via Supabase subscriptions |
| Feature | Description |
|---|---|
| π Admin Dashboard | View all links (active, inactive, broken) |
| π Link Management | Change link status or delete unworking tools |
| π₯ User Management | View user roles and permissions |
| π Real-time Monitoring | See all changes across the platform instantly |
| Component | Technology |
|---|---|
| Frontend | |
| Styling | |
| Authentication | |
| Database | |
| Real-time | |
| Deployment |
# Clone the repository
git clone https://github.com/yourusername/Developer_Resource_Hub.git
# Navigate into the project directory
cd Developer_Resource_Hub
# Install dependencies
npm installClick to expand
- Visit supabase.com
- Click "Start your project" or "Sign Up"
- Sign up using your GitHub account or email
- Verify your email if required
Click to expand
- After signing in, click "New Project"
- Select your organization (or create a new one)
- Fill in the project details:
- Project Name: Developer Resource Hub (or your preferred name)
- Database Password: Create a strong password and save it securely
- Region: Choose the region closest to you
- Click "Create new project"
- Wait for the project to be set up (this may take a few minutes)
Option A β From Settings β API
- Once your project is ready, navigate to Settings > API
- You'll find your credentials under the "Project API keys" section:
- Project URL: Something like
https://xxxxxxxxxxxxx.supabase.co - anon public: A long JWT token starting with
eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9... - service_role: Another JWT token (keep this secret)
- Project URL: Something like
Option B β From Connect β Next.js
Inside your Supabase project, at the top bar you'll see something like:
developer_resource_hub / main / Production / Connect
Click Connect.
Choose:
- App Frameworks β Next.js
- With App Router
- Using supabase-js
Supabase will show you a block like:
NEXT_PUBLIC_SUPABASE_URL=https://your-project-id.supabase.co NEXT_PUBLIC_SUPABASE_ANON_KEY=your-anon-key
These are the exact two values you need for this project.
β You do not need to copy any other connection strings for this app to work locally.
- In the root directory of your project, create a new file named
.env.local - Add the following environment variables to your
.env.localfile:
# Supabase Configuration
NEXT_PUBLIC_SUPABASE_URL=https://your-project-id.supabase.co
NEXT_PUBLIC_SUPABASE_ANON_KEY=your-anon-key-here
NEXT_PUBLIC_DEV_SUPABASE_REDIRECT_URL=http://localhost:3000Note: Replace the placeholder values with your actual Supabase credentials. The database connection strings are optional for most use cases but included for completeness.
- In your Supabase dashboard, navigate to SQL Editor in the left sidebar
- Click on "New query" to open a new SQL editor window
- Open the
scripts/001_create_tables.sqlfile in your local project - Copy the entire content of the file
- Paste it into the Supabase SQL Editor
- Click "Run" to execute the SQL script
- Wait for the script to complete (you should see a success message)
This script will create:
- A
profilestable that extends theauth.userstable - A
linkstable for storing resource links - Row Level Security (RLS) policies for both tables
- Triggers to automatically create a profile when a new user signs up
- Start your development server (if not already running):
npm run dev
- Open http://localhost:3000 in your browser
- Navigate to the registration page or use
/auth/register - Create a new account with your email and a secure password
- Check your email for a verification link and click it to verify your account
- Go back to the Supabase dashboard
- Navigate to SQL Editor and open a new query
- Run the following SQL to grant admin privileges to your user:
UPDATE public.profiles
SET role = 'admin'
WHERE email = '[email protected]';Replace [email protected] with the email you used to register.
- Verify the admin role was assigned:
SELECT id, email, role FROM public.profiles WHERE email = '[email protected]';You should see your email with the role set to admin.
Now you're ready to run the application:
npm run devOpen http://localhost:3000 in your browser to see the application running.
- You can sign in with your admin account
- Access the admin dashboard at
/admin - Start adding and managing resources
graph TD
A[app/] --> B[page.tsx]
A --> C[auth/]
A --> D[admin/]
A --> E[profile/]
A --> F[submit-link/]
C --> G[login/]
C --> H[register/]
C --> I[forgot-password/]
C --> J[reset-password/]
C --> K[callback/]
L[components/] --> M[auth/user-menu.tsx]
L --> N[links/]
L --> O[filters-bar.tsx]
L --> P[site-header.tsx]
Q[lib/supabase/]
R[scripts/]
| Security Feature | Description |
|---|---|
| π‘οΈ Row-Level Security (RLS) | All tables protected with RLS policies |
| π€ User Isolation | Users can only view/edit their own data |
| π Admin Access | Admins can manage all links |
| βοΈ Email Verification | Required for account activation |
| π Password Reset | Secure email-based password recovery |
# 1. Push your code to GitHub
git add .
git commit -m "Ready for deployment"
git push origin main
# 2. Import repository on https://vercel.com
# 3. Add environment variables:
# - NEXT_PUBLIC_SUPABASE_URL
# - NEXT_PUBLIC_SUPABASE_ANON_KEY
# 4. Deploy"User not authenticated"
- Verify email is confirmed
- Check Supabase session is valid
- Try logging out and back in
Links not appearing
- Ensure link status is 'active'
- Check RLS policies in Supabase
- Check browser console for errors
Admin dashboard not accessible
- Verify user role is 'admin' in profiles table
- Log out and back in
Database Connection Issues
- Verify your Supabase credentials in
.env.local - Check if your database is paused in Supabase dashboard
- Ensure your SQL scripts ran successfully
Made with β€οΈ by the Developer Resource Hub Team
β Star this repo if it helped you!