A complete web application for logo design services with user authentication and project management.
- Modern Responsive Design: Built with HTML5, CSS3, and JavaScript
- User Authentication: Login, registration, and session management
- Interactive UI: Smooth animations, hover effects, and transitions
- Dashboard: User project management and statistics
- Portfolio: Showcase of logo designs
- Pricing: Three-tier pricing structure
- Contact Form: Lead generation and customer inquiries
- RESTful API: Express.js server with SQLite database
- Secure Authentication: JWT tokens with bcrypt password hashing
- Database: SQLite with users, projects, and messages tables
- Security: Rate limiting, CORS, helmet protection
- Validation: Input validation and sanitization
Logo app/
├── index.html # Main landing page
├── dashboard.html # User dashboard
├── styles.css # Complete styling
├── script.js # Frontend JavaScript
├── api.js # API service layer
├── server.js # Backend server
├── package.json # Node.js dependencies
├── .env # Environment variables
├── database/ # SQLite database (auto-created)
└── README.md # This file
- Node.js (v14 or higher)
- npm or yarn
-
Install Dependencies
cd "c:/Users/Ghost/Desktop/Logo app" npm install
-
Environment Configuration
The
.envfile is already configured for development:PORT=3000 NODE_ENV=development DB_PATH=./database/logocraft.db JWT_SECRET=your-super-secret-jwt-key-change-this-in-production JWT_EXPIRES_IN=7d FRONTEND_URL=http://localhost:8000 -
Start Backend Server
npm start
For development with auto-restart:
npm run dev
-
Start Frontend Server
# In the same directory, run: python -m http.server 8000 -
Access the Application
- Frontend: http://localhost:8000
- Backend API: http://localhost:3000
- API Health Check: http://localhost:3000/api/health
POST /api/register- Register new userPOST /api/login- User loginGET /api/profile- Get user profile (protected)
GET /api/projects- Get user projects (protected)POST /api/projects- Create new project (protected)
GET /api/messages- Get user messages (protected)
GET /api/health- Health check endpoint
CREATE TABLE users (
id INTEGER PRIMARY KEY AUTOINCREMENT,
name TEXT NOT NULL,
email TEXT UNIQUE NOT NULL,
password TEXT NOT NULL,
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
updated_at DATETIME DEFAULT CURRENT_TIMESTAMP,
is_active BOOLEAN DEFAULT 1
);CREATE TABLE projects (
id INTEGER PRIMARY KEY AUTOINCREMENT,
user_id INTEGER NOT NULL,
name TEXT NOT NULL,
description TEXT,
package TEXT NOT NULL,
status TEXT DEFAULT 'pending',
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
updated_at DATETIME DEFAULT CURRENT_TIMESTAMP,
FOREIGN KEY (user_id) REFERENCES users (id)
);CREATE TABLE messages (
id INTEGER PRIMARY KEY AUTOINCREMENT,
user_id INTEGER NOT NULL,
subject TEXT NOT NULL,
message TEXT NOT NULL,
is_read BOOLEAN DEFAULT 0,
created_at DATETIME DEFAULT CURRENT_TIMESTAMP,
FOREIGN KEY (user_id) REFERENCES users (id)
);- Password Hashing: bcrypt with salt rounds
- JWT Authentication: Secure token-based authentication
- Input Validation: Email validation and password requirements
- Rate Limiting: Prevent brute force attacks
- CORS Protection: Cross-origin request security
- Helmet: Security headers for Express.js
- Registration: Click "Sign Up" to create a new account
- Login: Use your credentials to access the dashboard
- Dashboard: View projects, statistics, and manage orders
- Order Logo: Select a pricing package and submit your requirements
- Uses modern JavaScript (ES6+)
- Responsive design with CSS Grid and Flexbox
- Component-based architecture
- Smooth animations and transitions
- RESTful API design
- Middleware for authentication and validation
- Error handling and logging
- Graceful shutdown handling
For production deployment:
-
Environment Variables
- Change
JWT_SECRETto a secure random string - Set
NODE_ENV=production - Update
FRONTEND_URLto your domain
- Change
-
Security
- Use HTTPS
- Implement proper session management
- Add database backups
- Set up monitoring and logging
-
Database
- Consider migrating to PostgreSQL or MySQL for production
- Implement proper database indexing
- Set up regular backups
For issues or questions:
- Check the console for error messages
- Verify both frontend and backend are running
- Ensure database permissions are correct
- Check network connectivity between frontend and backend
MIT License - Feel free to use this project for learning and development.