This is the frontend of the Book Shop application. It is built using React.js and styled with Tailwind CSS, providing a responsive and user-friendly interface for users to explore, borrow, and manage books.
- User Authentication: Email-password-based authentication and social login.
- Book Categories: Browse books by categories.
- Book Details: View detailed information about each book.
- Borrow Books: Borrow books with real-time updates to inventory.
- Protected Routes: Access control for authenticated users.
- Dynamic Title: Route-based dynamic page titles.
- Responsive Design: Fully optimized for different screen sizes.
- React.js
- Tailwind CSS
- Axios
- React Router
- Firebase Authentication
- SweetAlert2 (for notifications)
- React-Query (optional for state management)
- Clone the repository:
git clone https://github.com/programming-hero-web-course2/b10a11-client-side-ataurwd.git cd frontend-repo - Install dependencies:
npm install
- Create a
.env.localfile and configure the following environment variables:REACT_APP_API_URL=<Your Backend API URL> REACT_APP_FIREBASE_API_KEY=<Your Firebase API Key> REACT_APP_FIREBASE_AUTH_DOMAIN=<Your Firebase Auth Domain>
- Start the development server:
npm start
npm start: Runs the app in development mode.npm run build: Builds the app for production.npm test: Launches the test runner.
src/
├── components/
├── pages/
├── context/
├── hooks/
├── styles/
├── App.js
├── index.js
The app is hosted on Firebase Hosting. To deploy:
- Build the project:
npm run build
- Deploy to Firebase:
firebase deploy
This project is licensed under the MIT License.