This is the frontend of the CFMS (Category and Subcategory Management System), built using Next.js. The project is designed to manage categories and subcategories efficiently with a modern UI and robust functionality. It provides a seamless user experience for managing data, integrating APIs, and ensuring responsiveness across devices.
- Responsive Design:
- Optimized for both desktop and mobile devices.
- Ensures a consistent user experience across different screen sizes.
- Modern UI Components:
- Built with reusable and accessible components.
- Includes dropdowns, modals, tables, and form validations.
- API Integration:
- Seamless integration with backend services for data fetching and manipulation.
- Uses
react-queryfor efficient state management and caching.
- Localization Support:
- Multi-language support for a global audience.
- Easily extendable for additional languages.
- Real-Time Notifications:
- Displays real-time updates and notifications for user actions.
- Data Validation:
- Implements robust validation using
zodschemas for form inputs and API requests.
- Implements robust validation using
Follow these steps to set up and run the project locally:
Ensure you have the following installed:
-
Clone the repository:
git clone https://github.com/SP25SE153-CFMS/CFMS-Frontend cd cfms-frontend -
Install dependencies:
yarn install # or npm install -
Set up environment variables:
Copy
.env.exampleto.envand configure the required variables:cp .env.example .env
Example
.envfile:NEXT_PUBLIC_API_URL=https://api.example.com NEXT_PUBLIC_ENV=development
Start the development server:
npm run dev
# or
yarn devOpen http://localhost:3000 in your browser to see the application.
To build the project for production:
npm run build
# or
yarn buildStart the production server:
npm run start
# or
yarn startsrc/
├── app/ # Application pages and layouts
├── components/ # Reusable UI components
├── configs/ # Configuration files
├── context/ # React context providers
├── hooks/ # Custom React hooks
├── lib/ # Utility functions
├── services/ # API service functions
├── styles/ # Global and component-specific styles
├── utils/ # Helper functions and schemas
└── public/ # Static assets (images, icons, etc.)
- Framework: Next.js
- State Management: React Query
- Validation: Zod
- Styling: Tailwind CSS
- Icons: Lucide React
- Notifications: React Hot Toast
- API Integration: Axios
- Date Handling: Day.js
We welcome contributions to improve this project! To contribute:
- Fork the repository.
- Create a new branch for your feature or bug fix:
git checkout -b feature-name
- Commit your changes:
git commit -m "Add new feature" - Push to your branch:
git push origin feature-name
- Open a pull request on GitHub.
To learn more about the tools and technologies used in this project, check out the following resources:
- Next.js Documentation - Learn about Next.js features and API.
- React Query Documentation - Learn about efficient state management.
- Zod Documentation - Learn about schema validation.
- Tailwind CSS Documentation - Learn about utility-first CSS.
The easiest way to deploy this application is to use the Vercel Platform. Check out the Next.js deployment documentation for more details.
This project is licensed under the MIT License.
Feel free to contribute to this project by submitting issues or pull requests!