|
1 | | -# Welcome to React Router! |
| 1 | +# M-Tech Portfolio |
2 | 2 |
|
3 | | -A modern, production-ready template for building full-stack React applications using React Router. |
| 3 | +A modern, responsive company portfolio built with React, TypeScript, and Vite. |
4 | 4 |
|
5 | 5 | ## Features |
6 | 6 |
|
7 | | -- 🚀 Server-side rendering |
8 | | -- ⚡️ Hot Module Replacement (HMR) |
9 | | -- 📦 Asset bundling and optimization |
10 | | -- 🔄 Data loading and mutations |
11 | | -- 🔒 TypeScript by default |
12 | | -- 🎉 CSS Modules for styling |
13 | | -- 📖 [React Router docs](https://reactrouter.com/) |
| 7 | +- 🚀 Pure React (no routing framework) |
| 8 | +- ⚡ Vite for fast development and optimized builds |
| 9 | +- 🎨 Glass morphism design with gradient effects |
| 10 | +- 📱 Fully responsive with mobile menu |
| 11 | +- 💌 EmailJS integration for contact form |
| 12 | +- 🎯 Hash-based client-side navigation |
| 13 | +- 🔧 TypeScript for type safety |
| 14 | +- 🎨 CSS Modules for scoped styling |
14 | 15 |
|
15 | | -### Styling & Theming |
| 16 | +## Project Structure |
16 | 17 |
|
17 | | -- This project uses CSS modules as the styling solution, Radix as the component library, and Open Props for styling tokens and theming |
18 | | -- Project theme is defined in `app/styles/theme.css`, used as a design system for all UI building |
19 | | -- Base design tokens are defined in `app/styles/tokens/<token-type>.css`, used as an immutable base design system for all the theme and all UI |
| 18 | +``` |
| 19 | +src/ |
| 20 | +├── components/ # Reusable UI components |
| 21 | +│ ├── ui/ # UI library components (buttons, cards, etc.) |
| 22 | +│ ├── Navigation.tsx |
| 23 | +│ └── Footer.tsx |
| 24 | +├── pages/ # Page components |
| 25 | +│ ├── Home.tsx |
| 26 | +│ ├── About.tsx |
| 27 | +│ ├── Services.tsx |
| 28 | +│ ├── Projects.tsx |
| 29 | +│ └── Contact.tsx |
| 30 | +├── data/ # Mock data |
| 31 | +├── hooks/ # Custom React hooks |
| 32 | +├── services/ # Business logic (email service) |
| 33 | +├── styles/ # Global styles and tokens |
| 34 | +├── App.tsx # Main app component with routing |
| 35 | +└── main.tsx # Entry point |
| 36 | +``` |
20 | 37 |
|
21 | 38 | ## Getting Started |
22 | 39 |
|
23 | | -### Installation |
24 | | - |
25 | | -Install the dependencies: |
| 40 | +### Install Dependencies |
26 | 41 |
|
27 | 42 | ```bash |
28 | 43 | npm install |
29 | 44 | ``` |
30 | 45 |
|
31 | 46 | ### Development |
32 | 47 |
|
33 | | -Start the development server with HMR: |
34 | | - |
35 | 48 | ```bash |
36 | 49 | npm run dev |
37 | 50 | ``` |
38 | 51 |
|
39 | | -Your application will be available at `http://localhost:5173`. |
40 | | - |
41 | | -## Building for Production |
| 52 | +Open [http://localhost:5173](http://localhost:5173) in your browser. |
42 | 53 |
|
43 | | -Create a production build: |
| 54 | +### Build for Production |
44 | 55 |
|
45 | 56 | ```bash |
46 | 57 | npm run build |
47 | 58 | ``` |
48 | 59 |
|
| 60 | +The build output will be in the `dist/` directory. |
| 61 | + |
| 62 | +### Preview Production Build |
| 63 | + |
| 64 | +```bash |
| 65 | +npm run preview |
| 66 | +``` |
| 67 | + |
| 68 | +## Navigation |
| 69 | + |
| 70 | +The app uses hash-based routing: |
| 71 | + |
| 72 | +- `#home` - Home page |
| 73 | +- `#about` - About us |
| 74 | +- `#services` - Services listing |
| 75 | +- `#projects` - Portfolio projects |
| 76 | +- `#contact` - Contact form |
| 77 | + |
| 78 | +## EmailJS Setup |
| 79 | + |
| 80 | +To enable the contact form: |
| 81 | + |
| 82 | +1. Sign up at [EmailJS](https://www.emailjs.com/) |
| 83 | +2. Create a service and email template |
| 84 | +3. Copy `.env.example` to `.env` |
| 85 | +4. Add your EmailJS credentials |
| 86 | + |
| 87 | +See `EMAILJS_SETUP.md` for detailed instructions. |
| 88 | + |
49 | 89 | ## Deployment |
50 | 90 |
|
51 | | -### DIY Deployment |
| 91 | +The built static files can be deployed to any static hosting service: |
52 | 92 |
|
53 | | -If you're familiar with deploying Node applications, the built-in app server is production-ready. |
| 93 | +- **GitHub Pages**: Copy `dist/` contents to your gh-pages branch |
| 94 | +- **Netlify**: Deploy the `dist/` folder |
| 95 | +- **Vercel**: Deploy the `dist/` folder |
| 96 | +- **Cloudflare Pages**: Deploy the `dist/` folder |
54 | 97 |
|
55 | | -Make sure to deploy the output of `npm run build` |
| 98 | +### Build Output |
56 | 99 |
|
57 | 100 | ``` |
58 | | -├── package.json |
59 | | -├── package-lock.json (or pnpm-lock.yaml, or bun.lockb) |
60 | | -├── build/ |
61 | | -│ ├── client/ # Static assets |
62 | | -│ └── server/ # Server-side code |
| 101 | +dist/ |
| 102 | +├── index.html |
| 103 | +├── assets/ |
| 104 | +│ ├── index-[hash].js |
| 105 | +│ └── index-[hash].css |
| 106 | +└── [static assets] |
63 | 107 | ``` |
| 108 | + |
| 109 | +## Technologies |
| 110 | + |
| 111 | +- **React 19** - UI library |
| 112 | +- **TypeScript** - Type safety |
| 113 | +- **Vite** - Build tool |
| 114 | +- **CSS Modules** - Scoped styling |
| 115 | +- **Lucide React** - Icons |
| 116 | +- **Radix UI** - Accessible components |
| 117 | +- **EmailJS** - Email service |
| 118 | +- **React Hook Form** - Form management |
| 119 | +- **Sonner** - Toast notifications |
| 120 | + |
| 121 | +## License |
| 122 | + |
| 123 | +Private project - All rights reserved |
0 commit comments