Skip to content

FaiazMahmud/DKP

Repository files navigation

id file_bmxzc1q7
filetype document
filename README
created_at 2026-04-09T16:22:01.868Z
updated_at 2026-04-09T16:22:01.869Z
meta
location tags categories description source
/
markdown

Digital-Knowledge-Platform

A modern Digital Knowledge Platform for creating, organizing, and sharing academic resources in a structured, searchable, and collaborative environment.

Prerequisites

Check versions:

node -v
npm -v
git --version

Project Structure

  • frontend: Frontend application source (UI, pages, components).
  • backend: Backend API and business logic.
  • shared: Shared constants, types, and reusable contracts.
  • docs: Project documentation and design notes.
  • infra: Infrastructure and deployment-related files.
  • scripts: Utility scripts for local setup and automation.
  • to_do_for_tamim.md: Sprint and implementation task plan.
  • understanding.md: Project understanding notes.
  • .env.example: Root environment variable template.

Quick Start (New User)

  1. Clone the repository:
git clone https://github.com/shahriarkabir280/Digital-Knowledge-Platform.git
cd Digital-Knowledge-Platform
  1. Go to frontend app:
cd frontend
  1. Create frontend environment file:
cp .env.example .env
  1. Install dependencies:
npm install
  1. Run development server:
npm run dev
  1. Open in browser:
http://localhost:5173/

Stop the server anytime with Ctrl + C.

Backend Setup and Run

  1. Open a new terminal and go to backend:
cd backend
  1. Create backend environment file:
cp .env.example .env
  1. Get Supabase connection string:

    • Go to https://supabase.com/dashboard
    • Select your project
    • Go to Settings → Database
    • Copy the connection string under "JDBC" or "PostgreSQL"
    • Paste into backend/.env as DATABASE_URL
  2. Install dependencies:

npm install
  1. Run backend in development mode:
npm run dev
  1. Verify backend is running:
http://localhost:3000/health
http://localhost:3000/api/status

Stop backend with Ctrl + C.

Run Frontend and Backend Together

Use two terminals:

  • Terminal 1:
cd frontend
npm run dev
  • Terminal 2:
cd backend
npm run dev

Note: You can now run npm run dev from the repo root, or run npm run dev separately from frontend and backend folders.

Database Setup (Supabase)

  1. Create a Supabase project at https://supabase.com
  2. Go to Project Settings → Database
  3. Copy the connection string (PostgreSQL URI)
  4. Paste it into backend/.env as DATABASE_URL
  5. The backend will automatically connect on startup

Useful Commands (Frontend)

npm run dev      # Start dev server
npm run build    # Build for production
npm run preview  # Preview production build
npm run lint     # Run lint checks

Troubleshooting

  • Port already in use:
npm run dev -- --port 5174
  • If dependencies fail to install, remove lock and retry:
rm -rf node_modules package-lock.json
npm install

Current Status

  • Frontend scaffold is ready and runnable.
  • Backend API is runnable with Supabase connectivity.
  • Core database functionality is in place.

Local Run and Deploy Note

  • Local development currently runs with two terminals (frontend and backend) using npm run dev.
  • Database is managed by Supabase - no local Docker services needed.
  • Simple, clean setup focused on Supabase.

About

Digital Knowledge Platform

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages