✨ SadhanaBoard is a comprehensive spiritual productivity and mindfulness application designed to help users track their spiritual practices, set intentions, and cultivate deeper awareness through gamified elements and cosmic themes. 🚀
- Features
- Technology Stack
- Theme System
- Project Structure
- Development Setup
- Environment Variables
- Database Setup
- Running the Application
- Building for Production
- API Documentation
- Admin Panel
- Scripts
- Deployment
- Contributing
- License
- 📈 Track spiritual practices and habits
- 🎯 Set intentions and goals
- 🌌 Cosmic-themed UI with multiple spiritual themes
- 📊 Progress tracking and insights
- 👥 Community features and social sharing
- 🧘 Meditation and mindfulness tools
- 📚 Book reading progress tracking
- 🙏 Group sadhanas and community participation
- 👤 Personal profile management
- ⚙️ Settings customization
- 📈 Analytics and reporting
- 🔔 Real-time notifications
- 🎮 Gamification elements
- Deity Interfaces: 🙏 Connect with higher self through deity representations
- Chakra Visualization: 🌈 Interactive chakra energy display
- Sacred Geometry: ⬣ Sri Yantra and other yantra visualizations
- Shadow Work: 🌒 Monitor shadow aspects and light integration
- Sound System: 🎵 Divine sounds and ambient background audio
- Meditation Guidance: 🤖 AI-powered spiritual guidance
- Framework: ⚛️ React with TypeScript
- Build Tool: ⚡ Vite
- State Management: 🔄 React Context API + Custom Hooks
- UI Components: 🧩 Radix UI + shadcn-ui
- Styling: 🎨 Tailwind CSS
- Routing: 🔗 React Router
- Data Fetching: 📡 React Query (@tanstack/react-query)
- Forms: 📝 React Hook Form + Zod
- Animations: 🎬 Framer Motion, Anime.js, GSAP
- 3D Graphics: 🎮 react-three/fiber + drei
- Icons: 🖼️ Lucide React
- Framework: 🟢 Node.js + Express
- Database: 🗄️ PostgreSQL
- Authentication: 🔐 JWT-based
- File Storage: 💾 Local file system
- Real-time: ⚡ Socket.IO
- API Documentation: 📖 RESTful endpoints
- Language: 📘 TypeScript
- Package Manager: 📦 npm
- Linting: 🧹 ESLint
- Testing: 🧪 Jest (planned for future implementation)
🧘♀️ SadhanaBoard includes a sophisticated theme system with 17+ spiritual themes:
- Default - 🧼 Clean, minimal theme
- Shiva - ⚡ Cosmic destroyer theme
- Mahakali - 🔱 Powerful goddess theme with animated 3D background
- Mystery - 🌑 Enigmatic dark theme
- Earth - 🌱 Grounding nature theme
- Water - 💧 Flowing aquatic theme
- Fire - 🔥 Energetic flame theme
- Bhairava - ⚔️ Fierce protector theme
- Serenity - ☀️ Peaceful light theme
- Ganesha - 🐘 Remover of obstacles theme
- Neon - ✨ Modern cyber-tech theme with vibrant neon gradients
- Lakshmi - 💰 Golden prosperity theme inspired by Goddess Lakshmi
- Mystical Forest - 🌳 Enchanted woodland theme with nature spirits
- Tara - 💀🌺 Mahavidya theme representing liberation and transformation
- Vishnu - 🌊💙 The Preserver theme with oceanic blue tones
- Krishna - 🎵💚 The Divine Cowherd theme with pastoral green tones
- Swamiji - 🔥🧡 Enlightened masters theme with guru wisdom
The Mahakali theme features a dynamic 3D animated background using Three.js. It requires specific assets to function properly:
mahakali-yantra.png- 🌀 The central yantra textureSkull and Bone Turnaround.gif- 💀 Theme icon
The theme system is built with the following components:
- Theme Registry - Centralized theme management in
src/themes/index.ts - Theme Definitions - Individual theme configurations with metadata, colors, and assets
- Theme Provider - React context provider that applies themes to the application
- Theme Utilities - Helper functions for applying theme colors and CSS
- Appearance Settings - UI component for theme selection and customization
When a user selects a theme:
- The ThemeProvider detects the change via useEffect
- Theme colors are applied as CSS custom properties to the document root
- Optional theme-specific CSS files are loaded
- The page automatically reloads to ensure complete theme application
- A loading indicator is shown during the reload process
Each theme consists of:
metadata- Theme information (id, name, description, deity, category)colors- Color definitions for all UI elementsassets(optional) - Paths to theme assets (icons, backgrounds, CSS)BackgroundComponent(optional) - React component for animated backgroundsavailable- Whether the theme is available for usecreatedAt- Theme creation date
Theme assets are managed through a series of npm scripts:
# Ensure all theme assets are in place
npm run themes:ensure-assets
# Generate theme manifest
npm run themes:generate
# Copy theme icons from root icons/ directory
npm run themes:copy-icons
# Move and optimize assets
npm run assets:move
# Run all setup scripts (used in dev and build)
npm run dev:setup-
Missing public/icons directory: 📁 The
themes:ensure-assetsscript will create this directory if missing. -
Mahakali theme background not rendering:
- Check that
public/icons/mahakali-yantra.pngexists and is a valid image file - Run
npm run dev:setupto ensure assets are properly copied - The system will use a procedural fallback if the texture fails to load
- Check that
-
Theme icons not loading:
- Run
npm run themes:copy-iconsto copy icons from the rooticons/directory - Check that the source icons exist in the
icons/directory
- Run
-
Theme switching issues:
- Verify that all themes are properly registered in
src/themes/index.ts - Check browser console for theme-related errors
- Verify that all themes are properly registered in
saadhanaboard/
├── backend/
│ ├── config/ # ⚙️ Database configuration
│ ├── controllers/ # 🎮 Request handlers
│ ├── middleware/ # 🔧 Express middleware
│ ├── models/ # 🗄️ Data models
│ ├── routes/ # 🔗 API routes
│ ├── services/ # 🏭 Business logic
│ ├── utils/ # 🛠️ Utility functions
│ ├── package.json # 📦 Backend dependencies
│ └── server.js # 🚀 Entry point
├── public/ # 🌐 Static assets
├── src/
│ ├── components/ # 🧩 React components
│ │ ├── deity/ # 🙏 Deity-related components
│ │ ├── library/ # 📚 Library components
│ │ ├── sadhana/ # 🙏 Sadhana components
│ │ ├── settings/ # ⚙️ Settings components
│ │ └── ui/ # 🎨 Shared UI components
│ ├── hooks/ # 🎣 Custom React hooks
│ ├── lib/ # 📚 Core utilities and context
│ ├── pages/ # 📄 Page components
│ ├── services/ # 📡 API service layer
│ ├── styles/ # 🎨 CSS and styling files
│ ├── themes/ # 🎨 Theme configurations
│ ├── types/ # 📝 TypeScript types
│ └── utils/ # 🛠️ Helper functions
├── supabase/ # 🗄️ Database migrations (reference)
├── package.json # 📦 Frontend dependencies
└── vite.config.ts # ⚙️ Vite configuration
- 🟢 Node.js (v18+)
- 🗄️ PostgreSQL database
- 📦 npm package manager
-
Clone Repository 📥
git clone <repository-url> cd saadhanaboard
-
Install Dependencies 📦
# Install frontend dependencies npm install # Install backend dependencies npm run backend:install
Create a .env file in the root directory:
# API Configuration
VITE_API_BASE_URL=http://localhost:3004/api
# Socket base URL (use http(s) here; debug tooling or the app may convert to ws:// when needed)
VITE_SOCKET_BASE_URL=http://localhost:3004
# When true, the frontend will include credentials (cookies) on requests
VITE_API_USE_CREDENTIALS=true
# Admin Configuration
ADMIN_USERNAME=admin
ADMIN_PASSWORD=password
# Development Configuration
VITE_DEV_MODE=true
# WebSocket reconnection strategy
VITE_WS_RECONNECT_ATTEMPTS=5
VITE_WS_RECONNECT_DELAY=1000
# Feature-specific debug flags
VITE_DEBUG_API=false
VITE_DEBUG_AUTH=false
# Notes:
# - Do NOT commit real secrets to source control. Replace values with CI/secret-managed values for production.
# - If your backend runs on a different port, update VITE_API_BASE_URL and VITE_SOCKET_BASE_URL accordingly.
Create a .env file in the backend/ directory:
# Database Configuration
DB_USER=postgres
DB_HOST=localhost
DB_NAME=saadhanaboard
DB_PASSWORD=your_password_here
DB_PORT=5432
# Alternative: Direct Database URL
# DATABASE_URL=postgresql://user:password@host:port/database
# JWT Configuration
JWT_SECRET=your_jwt_secret_here
# Server Configuration
PORT=3004
BACKEND_URL=http://localhost:3004
# CORS Configuration
CORS_ORIGIN=http://localhost:5173
# Admin Authentication Configuration
ADMIN_USERNAME=admin
ADMIN_EMAIL=admin@saadhanaboard.com
ADMIN_PASSWORD=your_secure_admin_password_here
ADMIN_FORCE_UPDATE=0
# Demo Admin Configuration (for testing)
DEMO_ADMIN_EMAIL=kali@example.com
# Admin JWT Configuration
ADMIN_TOKEN_EXPIRES_IN=7d
# Polling Intervals (in milliseconds)
DASHBOARD_POLL_MS=15000
BI_POLL_MS=20000
SYSTEM_METRICS_POLL_MS=5000
# SSL Configuration (for production)
PGSSL=false
# Notes:
# - Do NOT commit real secrets to source control. Replace values with CI/secret-managed values for production.-
Create PostgreSQL Database 🆕
CREATE DATABASE saadhanaboard;
-
Run Database Initialization 🏗️
cd backend node utils/initDb.js
Start both frontend and backend servers:
# Terminal 1: Start frontend development server
npm run dev
# Terminal 2: Start backend development server
npm run backend:devThe application will be available at:
- Frontend: http://localhost:5173
- Backend API: http://localhost:3004/api
- Backend WebSocket: http://localhost:3004
# Build frontend
npm run build
# Start backend server
npm startRun tests with:
npm test- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Thanks to all contributors who have helped shape Saadhanaboard
- Inspired by the rich traditions of Hindu and Buddhist spiritual practices
- Built with modern web technologies for the best user experience
Saadhanaboard is a comprehensive spiritual productivity application designed to help users track their spiritual practices, manage spiritual resources, and connect with a community of like-minded practitioners.
- 📓 Sadhana Tracking: Track daily spiritual practices with customizable templates
- 📚 Spiritual Library: Manage spiritual books, notes, and reading progress
- 👥 Community: Connect with other practitioners and share experiences
- 📊 Analytics: Visualize progress and insights into spiritual journey
- 🎨 Themes: 17+ beautiful spiritual themes for personalized experience
- 📱 Responsive: Works on all devices from mobile to desktop
- 🔒 Secure: JWT-based authentication with role-based access control
- 🟢 Node.js (v18+)
- 🗄️ PostgreSQL database
- 📦 npm package manager
-
Clone Repository 📥
git clone <repository-url> cd saadhanaboard
-
Install Dependencies 📦
# Install frontend dependencies npm install # Install backend dependencies npm run backend:install
Create a .env file in the root directory:
# API Configuration
VITE_API_BASE_URL=http://localhost:3004/api
# Socket base URL (use http(s) here; debug tooling or the app may convert to ws:// when needed)
VITE_SOCKET_BASE_URL=http://localhost:3004
# When true, the frontend will include credentials (cookies) on requests
VITE_API_USE_CREDENTIALS=true
# Admin Configuration
ADMIN_USERNAME=admin
ADMIN_PASSWORD=password
# Development Configuration
VITE_DEV_MODE=true
# WebSocket reconnection strategy
VITE_WS_RECONNECT_ATTEMPTS=5
VITE_WS_RECONNECT_DELAY=1000
# Feature-specific debug flags
VITE_DEBUG_API=false
VITE_DEBUG_AUTH=false
# Notes:
# - Do NOT commit real secrets to source control. Replace values with CI/secret-managed values for production.
# - If your backend runs on a different port, update VITE_API_BASE_URL and VITE_SOCKET_BASE_URL accordingly.
Create a .env file in the backend/ directory:
# Database Configuration
DB_USER=postgres
DB_HOST=localhost
DB_NAME=saadhanaboard
DB_PASSWORD=your_password_here
DB_PORT=5432
# Alternative: Direct Database URL
# DATABASE_URL=postgresql://user:password@host:port/database
# JWT Configuration
JWT_SECRET=your_jwt_secret_here
# Server Configuration
PORT=3004
BACKEND_URL=http://localhost:3004
# CORS Configuration
CORS_ORIGIN=http://localhost:5173
# Admin Authentication Configuration
ADMIN_USERNAME=admin
ADMIN_EMAIL=admin@saadhanaboard.com
ADMIN_PASSWORD=your_secure_admin_password_here
ADMIN_FORCE_UPDATE=0
# Demo Admin Configuration (for testing)
DEMO_ADMIN_EMAIL=kali@example.com
# Admin JWT Configuration
ADMIN_TOKEN_EXPIRES_IN=7d
# Polling Intervals (in milliseconds)
DASHBOARD_POLL_MS=15000
BI_POLL_MS=20000
SYSTEM_METRICS_POLL_MS=5000
# SSL Configuration (for production)
PGSSL=false
# Notes:
# - Do NOT commit real secrets to source control. Replace values with CI/secret-managed values for production.-
Create PostgreSQL Database 🆕
CREATE DATABASE saadhanaboard;
-
Run Database Initialization 🏗️
cd backend node utils/initDb.js
Start both frontend and backend servers:
# Terminal 1: Start frontend development server
npm run dev
# Terminal 2: Start backend development server
npm run backend:devThe application will be available at:
- Frontend: http://localhost:5173
- Backend API: http://localhost:3004/api
- Backend WebSocket: http://localhost:3004
# Build frontend
npm run build
# Start backend server
npm startRun tests with:
npm test- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Thanks to all contributors who have helped shape Saadhanaboard
- Inspired by the rich traditions of Hindu and Buddhist spiritual practices
- Built with modern web technologies for the best user experience