LuisValgoi / ui5-webcomponents-react-seed

Seed of UI5 Web Components for React
12 stars 1 forks source link

Multiple Requests Fix #41

Closed isaqueha closed 3 years ago

isaqueha commented 3 years ago

Description

This PR fixes the issue https://github.com/LuisValgoi/ui5-webcomponents-react-seed/issues/28 The react-query cache was used to fix this. The staleTime property of the useQuery hook was set with 5 minutes.

Testing

  1. Open the application;
  2. Monitor the Network calls to the Backend;
  3. Check that the logged endpoint is not being re-called forever;

Automated Tests

References

isaqueha commented 3 years ago

For the reviewer: Can you run a yarn test:ci to check the solution on your side as well?