Skip to content

Rafiqdevhub/Rafiqdev

Repository files navigation

Muhammad Rafiq Portfolio

A modern, responsive portfolio website built with React, Vite, and Tailwind CSS. This portfolio showcases my projects, skills, and professional background in a clean and interactive interface with PWA support.

πŸ“‹ Features

  • Responsive Design: Works perfectly on all devices from mobile to desktop
  • Progressive Web App (PWA): Installable and works offline with service worker support
  • Modern UI: Beautiful gradient backgrounds with smooth scrolling and animations
  • Interactive Sections: Home, About, Projects, and Contact sections
  • Dynamic Project Showcase: Display projects with descriptions and technologies used
  • Skills Categories: Organized skills display with interactive tabs
  • AI-Powered Chatbot: Interactive assistant that answers questions about my experience and skills
  • Social Media Integration: Easy access to all professional profiles
  • Typewriter Effect: Engaging animated text on the home page
  • Archive Projects Page: View all projects in a dedicated page
  • Resume Access: Quick link to download/view resume

πŸ› οΈ Technologies Used

  • React 18 - Frontend library for building user interfaces
  • Vite - Next-generation frontend tooling
  • Tailwind CSS - Utility-first CSS framework
  • React Router - For navigation and routing
  • React Icons - Icon library
  • React Scroll - For smooth scrolling to page sections
  • Typewriter Effect - For animated text typing
  • Google Gemini AI - For powering the AI chatbot assistant
  • Vite PWA Plugin - For Progressive Web App capabilities
  • EmailJS - For contact form functionality

πŸš€ Getting Started

Prerequisites

  • Node.js (version 14.x or higher)
  • npm or yarn package manager

Installation

  1. Clone the repository
git clone https://github.com/Rafiqdevhub/Rafiqdev.git
cd Rafiqdev
  1. Install dependencies
npm install
# or
yarn install
  1. Start the development server
npm run dev
# or
yarn dev
  1. Open your browser and visit http://localhost:5173

πŸ“ Project Structure

β”œβ”€β”€ public/            # Public assets
β”‚   β”œβ”€β”€ manifest.json  # PWA manifest file
β”‚   β”œβ”€β”€ Rafiq.PNG      # App icon
β”‚   β”œβ”€β”€ robots.txt     # SEO configuration
β”‚   β”œβ”€β”€ sitemap.xml    # SEO sitemap
β”‚   └── sw.js          # Service Worker for PWA functionality
β”‚
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ Assets/        # Static assets
β”‚   β”‚   β”œβ”€β”€ images/    # Image files
β”‚   β”‚   └── svg/       # SVG icons for skills
β”‚   β”‚
β”‚   β”œβ”€β”€ components/    # Reusable UI components
β”‚   β”‚   β”œβ”€β”€ Cards.jsx  # Project card component
β”‚   β”‚   β”œβ”€β”€ Chatbot.jsx# AI assistant component
β”‚   β”‚   β”œβ”€β”€ Footer.jsx # Footer component
β”‚   β”‚   └── Header.jsx # Navigation header
β”‚   β”‚
β”‚   β”œβ”€β”€ data/          # Data files
β”‚   β”‚   β”œβ”€β”€ ProjectsList.js  # Project information
β”‚   β”‚   β”œβ”€β”€ SkillsData.js    # Skills list
β”‚   β”‚   └── UserData.js      # Personal information
β”‚   β”‚
β”‚   β”œβ”€β”€ pages/         # Page components
β”‚   β”‚   β”œβ”€β”€ About.jsx        # About page
β”‚   β”‚   β”œβ”€β”€ ArchiveProjects.jsx  # Projects archive
β”‚   β”‚   β”œβ”€β”€ Contact.jsx      # Contact page
β”‚   β”‚   β”œβ”€β”€ Home.jsx         # Home page
β”‚   β”‚   └── Project.jsx      # Projects section
β”‚   β”‚
β”‚   β”œβ”€β”€ utils/         # Utility functions
β”‚   β”‚   β”œβ”€β”€ chatbotResponses.js  # Chatbot logic
β”‚   β”‚   β”œβ”€β”€ geminiAI.js      # Google AI integration
β”‚   β”‚   β”œβ”€β”€ SkillsImage.js   # Skill icons mapping
β”‚   β”‚   └── serviceWorkerRegistration.js # PWA registration
β”‚   β”‚
β”‚   β”œβ”€β”€ App.css        # Global styles
β”‚   β”œβ”€β”€ App.jsx        # Main App component
β”‚   └── main.jsx       # Entry point
β”‚
β”œβ”€β”€ build.js           # Custom build script
β”œβ”€β”€ copy-pwa-assets.js # PWA asset preparation script
β”œβ”€β”€ vite.config.js     # Vite configuration
β”œβ”€β”€ tailwind.config.js # Tailwind CSS configuration
β”œβ”€β”€ vercel.json        # Vercel deployment config
└── netlify.toml       # Netlify deployment config

πŸ“„ Customization

Personal Information

Edit the data files in the src/data directory:

  • UserData.js - Your personal information, social links, resume URL, and typewriter options
  • ProjectsList.js - Your projects with descriptions, technologies, and GitHub links
  • SkillsData.js - Your technical skills organized by category

Images

Replace the images in the src/Assets/images directory with your own:

  • Rafiq.PNG - Your profile icon (also used for PWA)
  • AboutImage.png - Image shown in the About section
  • RafiqImage.svg - Your main profile image on the Home page

Colors & Styling

The main styling is defined in:

  • src/App.css - Contains CSS variables for theme colors and animations
  • tailwind.config.js - Custom Tailwind CSS configuration including animations and breakpoints

AI Chatbot

The chatbot is powered by Google Gemini AI. To customize:

  1. Edit the responses in src/utils/chatbotResponses.js
  2. Modify the AI context in src/utils/geminiAI.js

πŸ”§ Environment Variables

Create a .env file in the root directory with the following variables:

VITE_GEMINI_API_KEY=your_gemini_api_key
VITE_EMAIL_SERVICE_ID=your_emailjs_service_id
VITE_EMAIL_TEMPLATE_ID=your_emailjs_template_id
VITE_EMAIL_PUBLIC_KEY=your_emailjs_public_key

πŸ“¦ Build for Production

The project includes a custom build script with optimizations:

npm run build
# or
yarn build

This will:

  1. Clean previous build artifacts
  2. Copy PWA assets and configuration files
  3. Build the project with Vite optimizations
  4. Generate a build report

The output will be in the dist_new directory which is configured for deployment in vercel.json.

🚒 Deployment

This portfolio is configured for multiple deployment platforms:

Vercel (Recommended)

  • Already configured with vercel.json
  • Connect your GitHub repository to Vercel
  • Set the output directory to dist_new

Netlify

  • Configured with netlify.toml
  • Connect your GitHub repository to Netlify
  • The build command and publish directory are already set

Self-hosting

  • The build script generates optimal Apache server configuration
  • Upload the contents of dist_new to your web server
  • Make sure to configure proper routing for SPA

🌐 Browser Compatibility

This portfolio is optimized for modern browsers with:

  • Chrome/Edge (Latest)
  • Firefox (Latest)
  • Safari (Latest)
  • Mobile browsers (iOS Safari, Chrome for Android)

The PWA functionality allows users to install the portfolio as an app on compatible devices.

⚑ Performance Optimizations

The portfolio includes several optimizations:

  • Code splitting with React lazy loading
  • Image optimization with vite-imagetools
  • PWA caching for offline access
  • Tailwind CSS purging for minimal CSS
  • Custom animations with minimal performance impact
  • Memoized components for reduced re-renders

🀝 Contributing

Contributions are welcome! If you'd like to contribute:

  1. Fork the repository
  2. Create a new branch (git checkout -b feature/amazing-feature)
  3. Commit your changes (git commit -m 'Add some amazing feature')
  4. Push to the branch (git push origin feature/amazing-feature)
  5. Open a Pull Request

πŸ“ž Contact

Muhammad Rafiq - rafkhan9323@gmail.com

πŸ“œ License

This project is open source and available under the MIT License.

About

Personal Portfolio.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published