A React-based newsletter application for the Hope Family community.
- Authentication System: Complete login/signup functionality with JWT tokens
- Navigation: Responsive navigation with logout functionality
- Blog Management: Create and publish articles with media attachments
- Gallery: Photo and video sharing
- Birthday Tracking: Member birthday management
- Responsive Design: Mobile-first design with Tailwind CSS
The application now includes a complete authentication system:
- Users can log in with email and password
- JWT tokens are stored in localStorage
- Automatic redirect to home page after successful login
- Logout button is available in the navigation bar
- Clears authentication token and redirects to login page
- Available on both desktop and mobile views
- Articles page requires authentication
- Token is automatically included in API requests
-
Install dependencies:
npm install
-
Start the development server:
npm run dev
-
Make sure the backend server is running on
http://localhost:3008
POST /api/login- User authenticationPOST /api/signup- User registrationPOST /api/uploadBlog- Blog creation (requires authentication)
- React 18
- React Router DOM
- Tailwind CSS
- Axios for API calls
- Lucide React for icons
- Vite for build tooling
src/
├── components/ # React components
│ ├── Header.jsx # Navigation with logout
│ ├── Login.jsx # Authentication form
│ ├── Signup.jsx # Registration form
│ └── Articles.jsx # Blog creation
├── context/ # React context
│ └── AuthContext.jsx # Authentication state management
└── App.jsx # Main application component
- User visits the application
- If not authenticated, they see login/signup options
- After successful login, JWT token is stored
- User can access protected features like Articles
- Logout button clears token and redirects to login
The application uses Tailwind CSS with custom components:
- Glass morphism effects
- Gradient text and buttons
- Responsive navigation
- Modern form styling