Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Centralize loading component #249

Open
gjvera opened this issue Feb 25, 2020 · 1 comment
Open

Centralize loading component #249

gjvera opened this issue Feb 25, 2020 · 1 comment

Comments

@gjvera
Copy link
Contributor

gjvera commented Feb 25, 2020

Currently we have loading components that all use material-ui's LinearProgress, however they are all implemented differently.
Some declare a component and then return LinearProgress

const Loading = () => {

and some just return LinearProgress directly
if (loading) return <LinearProgress />

We should centralize it so all components grab it from the same place and return the same loading component. This will make it easier if we ever wanted to change the component.

@willwill96
Copy link
Contributor

We should make sure that we don't couple every loading state to a single loading component. I think we should have multiple centralized loading components for different use cases. i.e. routes shouldn't necessarily be using the same loading indicator as network retries

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants