A modern e-commerce platform for selling crystal products, built with a focus on user experience and international payment integration.
- 🛍️ Modern, responsive product catalog
- 💳 Multiple payment methods (Stripe, PayPal, Klarna, Affirm)
- 🔒 Secure checkout process
- 🌐 International shipping support
- 📱 Mobile-friendly design
- 🎨 Beautiful product showcase with 3D and AR views
- 📊 Advanced analytics integration
- 📧 Email marketing system
- 💎 Crystal energy reading feature
- Frontend: HTML5, CSS3, JavaScript
- Backend: Python (Flask)
- Database: MySQL
- Cache: Redis
- Payment Processing: Stripe, PayPal, Klarna, Affirm
- Analytics: Google Analytics 4, Facebook Pixel
- Node.js >= 14.0.0
- Python >= 3.8
- MySQL >= 8.0
- Redis >= 6.0
- Nginx >= 1.18
- Clone the repository:
git clone https://github.com/Cynthia-ly/crystal-shop.git
cd crystal-shop- Install frontend dependencies:
npm install- Set up Python virtual environment:
python -m venv venv
source venv/bin/activate # Linux/Mac
venv\Scripts\activate # Windows
pip install -r requirements.txt- Configure environment variables:
cp .env.example .env
# Edit .env with your configuration- Initialize the database:
flask db upgrade- Build the frontend:
npm run build- Start the development server:
# Terminal 1 - Frontend
npm start
# Terminal 2 - Backend
flask runCreate a .env file in the root directory with the following variables:
# Database
DB_HOST=localhost
DB_PORT=3306
DB_NAME=crystal_shop
DB_USER=your_username
DB_PASSWORD=your_password
# Redis
REDIS_HOST=localhost
REDIS_PORT=6379
REDIS_PASSWORD=your_redis_password
# Payment
STRIPE_PUBLIC_KEY=your_stripe_public_key
STRIPE_SECRET_KEY=your_stripe_secret_key
PAYPAL_CLIENT_ID=your_paypal_client_id
PAYPAL_SECRET=your_paypal_secret
KLARNA_CLIENT_ID=your_klarna_client_id
AFFIRM_PUBLIC_KEY=your_affirm_public_key
# Email
SMTP_HOST=smtp.gmail.com
SMTP_PORT=587
SMTP_USER=your_email@gmail.com
SMTP_PASSWORD=your_email_password
# Analytics
GA_TRACKING_ID=your_ga_tracking_id
FB_PIXEL_ID=your_fb_pixel_idcrystal-shop/
├── frontend/ # Frontend code
│ ├── js/ # JavaScript files
│ ├── css/ # Stylesheets
│ └── images/ # Image assets
├── backend/ # Backend code
│ ├── app/ # Application code
│ ├── tests/ # Test files
│ └── migrations/ # Database migrations
├── public/ # Static files
└── docs/ # Documentation
# Run backend tests
pytest
# Run frontend tests
npm testSee DEPLOYMENT.md for detailed deployment instructions.
- 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.