DevoteamNL / opendora

Team performance insights for your organization.
GNU General Public License v3.0
67 stars 8 forks source link

refactor(backstage-plugin): Extract logic to hooks #108

Closed kylejwatson closed 12 months ago

kylejwatson commented 1 year ago

Description

Extract out error/response logic from the component to a reusable hook to avoid complicated state in the component.

Use a context to provide metric details for the request to avoid prop drilling.

Create a reusable component to reuse logic for switching between a graph, loading bar or error.

Issue

This PR addresses issue #71.

Contribution Checklist:

Note: Keeping the PR small and focused helps make it easier to review and merge. If you have multiple changes you want to make, please consider submitting them as separate pull requests.