Open bLangved opened 8 months ago
@RiverMichael Dataene i API'en er altfor store for å bruke sessionStorage eller localStorage (maks data på rundt 10mb). Hver pokémon request tar omtrent 0.25mb, så en generasjon er fort en plass mellom 30-50mb. Går ann å bruke løsninger som "IndexedDB", som kan holde mye større mengder data, samt komprimere data på vei inn, og dekomprimere data når det trengs igjen, men dette har ikke jeg satt meg inn i.
Midlertidig løsning: Bruke pagination for å begrense hvor mange requests som gjøres ved hver pokemon generasjon, og man heller kan scrolle / klikke på en knapp for å hente mer.
What this issue is about:
Solution so that the user do not have to fetch all/selected pokemon (and generations) each time user wants to check
To-do's
Considerations
Using LocalStorage:
Using SessionStorage:
Hybrid Approach:
Relevant project paths
src/js/ src/js/fetchData