{"id":19109265,"url":"https://github.com/obrm/shoes-app-demo","last_synced_at":"2026-04-14T23:34:01.253Z","repository":{"id":197753421,"uuid":"697801035","full_name":"obrm/shoes-app-demo","owner":"obrm","description":"This is a Shoe CRUD application that allows users to Create, Read, Update, and Delete shoe entries. The app is integrated with a mock API for demonstration purposes.","archived":false,"fork":false,"pushed_at":"2024-01-17T15:36:55.000Z","size":378,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-22T10:57:33.411Z","etag":null,"topics":["axios","react","react-router","react-toastify"],"latest_commit_sha":null,"homepage":"https://obrm-shoe-app-demo.netlify.app","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/obrm.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-09-28T13:59:18.000Z","updated_at":"2023-10-03T12:58:20.000Z","dependencies_parsed_at":"2023-11-09T10:50:49.110Z","dependency_job_id":"3f611798-9578-4b5d-8599-06978f077558","html_url":"https://github.com/obrm/shoes-app-demo","commit_stats":null,"previous_names":["obrm/shoes-app-demo"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/obrm/shoes-app-demo","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obrm%2Fshoes-app-demo","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obrm%2Fshoes-app-demo/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obrm%2Fshoes-app-demo/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obrm%2Fshoes-app-demo/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/obrm","download_url":"https://codeload.github.com/obrm/shoes-app-demo/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/obrm%2Fshoes-app-demo/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31819880,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-14T18:05:02.291Z","status":"ssl_error","status_checked_at":"2026-04-14T18:05:01.765Z","response_time":153,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["axios","react","react-router","react-toastify"],"created_at":"2024-11-09T04:19:44.781Z","updated_at":"2026-04-14T23:34:01.237Z","avatar_url":"https://github.com/obrm.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Shoe CRUD App\n\n## Table of Contents\n\n- [Shoe CRUD App](#shoe-crud-app)\n  - [Table of Contents](#table-of-contents)\n  - [Acknowledgments](#acknowledgments)\n  - [Overview](#overview)\n  - [Live Demo](#live-demo)\n  - [Features](#features)\n  - [Tech Stack](#tech-stack)\n  - [Screenshots](#screenshots)\n    - [Home Screen](#home-screen)\n    - [Login Screen](#login-screen)\n    - [Shoe Screen](#shoe-screen)\n    - [Edit Shoe Screen](#edit-shoe-screen)\n    - [Error Toast](#error-toast)\n  - [Getting Started](#getting-started)\n  - [API Integration](#api-integration)\n    - [Environment Variable Protection](#environment-variable-protection)\n    - [Request Management](#request-management)\n  - [Context Management](#context-management)\n    - [Authentication Context](#authentication-context)\n    - [Shoe Context](#shoe-context)\n  - [Custom Hooks](#custom-hooks)\n    - [`useShoeForm`](#useshoeform)\n    - [`useLoginForm`](#useloginform)\n    - [`useShoe`](#useshoe)\n  - [User Experience](#user-experience)\n    - [Input Components](#input-components)\n    - [Shoe Card Components](#shoe-card-components)\n  - [Code Reusability](#code-reusability)\n  - [Error Management](#error-management)\n  - [License](#license)\n\n\n## Acknowledgments\n\nThis project is based on the [React Shoe Shop](https://github.com/MariaPinchasi/react-shoe-shop) repository created by Maria Pinchasi. Many of the architectural decisions, UI elements, and functionalities were inspired by her work. Special thanks to Maria for providing a robust foundation upon which this application could be built. Please add a star to her work!\n\n## Overview\n\nThis is a Shoe CRUD application that allows users to Create, Read, Update, and Delete shoe entries. The app is integrated with a mock API for demonstration purposes.\n\n## Live Demo\n\nVisit the [live demo](https://obrm-shoe-app-demo.netlify.app).\n\n## Features\n\n- CRUD Operations\n- Mock User Authentication\n- Global State Management\n- Custom Hooks\n- Error Notifications\n\n\n\n## Tech Stack\n\n- React.js\n- React Router\n- Axios\n- mockApi\n- react-toastify\n\n## Screenshots\n\n---\n### Home Screen\n![Home Screen](src/assets/home.png)\n\n---\n### Login Screen\n![Login Screen](src/assets/login.png)\n\n---\n\n### Shoe Screen\n![Shoe Screen](src/assets/shoe.png)\n\n---\n\n### Edit Shoe Screen\n![Manage Shoe Screen](src/assets/manage_shoe.png)\n\n---\n\n### Error Toast \n![Error Toast](src/assets/error.png)\n\n---\n## Getting Started\n\n1. Clone the repository from `https://github.com/obrm/shoes-app-demo`.\n2. Install dependencies with `npm install`.\n3. Add the `.env` file based on the `.env.sample` file included in the repository.\n4. Run the application using `npm run dev`.\n\n\n\n## API Integration\n\nAll the API calls are available in the `api.js` file in the `api` folder.\n### Environment Variable Protection\n\n- The API URL is secured in an `.env` file, which is omitted from the repository for security reasons. Refer to `.env.sample` for the expected variables.\n\n### Request Management\n\n- A generic request function is available for making API calls. This function is utilized in other utility functions designed for specific request types (GET, POST, PUT, DELETE).\n\n```javascript\nconst request = async (method, endpoint, data = null) =\u003e {\n    const res = await axios({\n        method,\n        url: `${BASE_URL}${endpoint}`,\n        data,\n    });\n    return res.data;\n};\n\nexport const getAllShoes = async () =\u003e {\n    return await request('get', '/');\n};\n\n// and so on...\n```\n\n\n\n## Context Management\n\n### Authentication Context\n\n- Manages user authentication and stores user details in local storage for persistence.\n\n### Shoe Context\n\n- This global state is responsible for getting all the shoes and is updated when a shoe is added, edited, or deleted. Ensures immediate reflection of changes across all components.\n\n\n\n## Custom Hooks\n\n### `useShoeForm`\n\n- Encapsulates the logic for the shoe form. Common logic for adding and editing a shoe is centralized here.\n\n### `useLoginForm`\n\n- Manages the logic for the login form.\n\n### `useShoe`\n\n- Additional custom hook is employed for separating logic and view in the `Shoe` component.\n\n\n## User Experience\n\n### Input Components\n\n- JSX repetition for input elements is avoided by creating reusable Input components. \n\n### Shoe Card Components\n\n- A `ShoeCard` component is used to iterate over the array of shoes and display them on the Home screen.\n\n\n## Code Reusability\n\n- A single `ManageShoe` component is used for both adding and editing shoes, depending on the presence of `shoeId` in the URL, avoiding the need to use two separate components.\n\n\n## Error Management\n\n- User-friendly error notifications are shown using the [`react-toastify`](https://www.npmjs.com/package/react-toastify) package. It's centralized in the App component to handle errors application-wide.\n\n\n## License\n\n- This project is licensed under the MIT License.\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fobrm%2Fshoes-app-demo","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fobrm%2Fshoes-app-demo","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fobrm%2Fshoes-app-demo/lists"}