Project Requirements - Dadarkp3/pokedex GitHub Wiki
Project Requirements
Functional Requirements
1. Search Functionality
- Users must be able to search for Pokémon by name.
- The search should be initiated by pressing the ENTER key.
- No action should occur if the input field is empty or if the input value is the same as the previous search.
- The input field should be disabled during the search to prevent multiple requests.
2. Input Control
- The input field must be controlled to handle user interactions correctly.
3. Display States
3.1 Loading State
Provide user feedback during the search (e.g., a loading indicator).
3.2 Initial/Empty State
Display a message indicating the user can search when the application starts or when no Pokémon are displayed.
3.3 Not Found State
Display a message indicating no results were found if the search returns no data.
3.4 Found State
Display the Pokémon if found.
4. Backend for Frontend (BFF) Communication
- The application must communicate with a BFF that interacts with the PokeAPI.
- The BFF must cache results to ensure service stability, even if the PokeAPI is unstable or down, and to conserve resources.
Non-Functional Requirements
1. Technology Stack
- The frontend application must be written in React.
- The choice of using frameworks (e.g., Next.js, Gatsby) is optional.
2. Repository and Documentation
- Share one or more repositories with the code.
- Include a README file with instructions on how to run the applications locally.
3. Optional Use of UI Component Libraries
- The use of UI Component Libraries is optional.
4. Local Deployment
- The applications do not need to be deployed online; they must be runnable locally.
These requirements outline the essential functionalities and considerations for the development and deployment of the Pokémon search application.