Skip to content

RnD-BNCC/bncc.in

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

95 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

BNCC.IN — URL Shortener & QR Code Generator

BNCC.IN Logo

License: MIT Node.js Next.js TypeScript MongoDB

A modern URL shortener and QR code generator with analytics dashboard


Interface Preview

Authentication Page
Authentication Page
Shorten Link / Generate QR Page
Shorten Link / Generate QR
Result Page
Result Page
Main Dashboard
Main Dashboard
Edit Dashboard
Edit Dashboard
Analytics Dashboard
Analytics Dashboard

Features

  • 🔗 URL Shortening - Create short, memorable links with custom aliases
  • 🎨 QR Code Generator - Generate customizable QR codes with branding options
  • 🔐 Authentication - Email, Google, and GitHub login support
  • 📊 Analytics Dashboard - Track clicks, referrers, and geographical data
  • 🔒 Link Protection - Passcode protection for sensitive links
  • Link Expiration - Set automatic expiration dates
  • ✏️ Link Management - Edit and organize your links easily

Tech Stack

Backend

Node.js (Express)
TypeScript
MongoDB (Mongoose)
Frontend

Next.js 14
React & TypeScript
Tailwind CSS
Auth

Passport.js
Google OAuth
GitHub OAuth

Quick Start

Prerequisites

  • Node.js 18 or higher
  • npm or yarn
  • MongoDB instance (local or Atlas)

Installation

1. Clone the repository

git clone https://github.com/pisciva/bncc.in.git
cd bncc.in

2. Install backend dependencies

cd backend
npm install

3. Install frontend dependencies

cd ../frontend
npm install

4. Configure environment variables

Create .env files in both backend/ and frontend/ directories with your configuration:

Backend .env:

# Server URLs
BACKEND_URL=http://localhost:5000
FRONTEND_URL=http://localhost:3000

# Database
MONGO_URI=your_mongodb_connection_string

# Security Secrets
JWT_SECRET=your_jwt_secret_key
SESSION_SECRET=your_session_secret_key

# Google OAuth
GOOGLE_CLIENT_ID=your_google_client_id
GOOGLE_CLIENT_SECRET=your_google_client_secret

# GitHub OAuth
GITHUB_CLIENT_ID=your_github_client_id
GITHUB_CLIENT_SECRET=your_github_client_secret

# Email Service (Resend)
RESEND_API_KEY=your_resend_api_keyy

Frontend .env:

NEXT_PUBLIC_API_URL=http://localhost:5000
NEXT_PUBLIC_SITE_URL=http://localhost:3000

5. Start the servers

Open two terminal windows:

Terminal 1 - Backend Server:

cd backend
npm run build
npm start

Backend runs on http://localhost:5000

Terminal 2 - Frontend Server:

cd frontend
npm run dev

Frontend runs on http://localhost:3000

You're all set! Visit http://localhost:3000 to see the application.


Project Structure

bncc.in/
├── backend/
│   ├── config/              # Database & OAuth configuration
│   ├── middleware/          # Express middleware
│   ├── models/              # MongoDB schemas
│   ├── routes/              # API endpoints
│   ├── utils/               # Helper functions
│   └── index.ts             # Server entry point
│
└── frontend/
    ├── app/                 # Next.js App Router
    ├── components/          # React components
    │   ├── layout/          # Layout components
    │   ├── main/            # Main page components
    │   └── dashboard/       # Dashboard components
    ├── context/             # React Context
    ├── hooks/               # Custom hooks
    ├── lib/                 # API client
    ├── utils/               # Utility functions
    └── public/              # Static assets

License

This project is licensed under the MIT License - see the LICENSE.md file for details.


Acknowledgments

Built with ❤️ by BNCC (Bina Nusantara Computer Club)

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages

  • TypeScript 95.5%
  • CSS 4.4%
  • JavaScript 0.1%