Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

add loading state for AD detail page #156

Closed

Conversation

ylwu-amzn
Copy link
Contributor

Issue #, if available:

Description of changes:

  • add loading state for AD detail page

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@ylwu-amzn ylwu-amzn linked an issue May 19, 2020 that may be closed by this pull request
@ylwu-amzn ylwu-amzn closed this May 19, 2020
</h1>
</EuiTitle>
</EuiFlexItem>
{!isEmpty(detector) ? (
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should consider hasError to handle exceptions like not found , timeout etc. If any problem occur, we already have code to pop up toast:

 useEffect(() => {
    if (hasError) {
      toastNotifications.addDanger('Unable to find detector');
      props.history.push('/detectors');
    }
  }, [hasError]);

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

Successfully merging this pull request may close these issues.

Fix loading state of detector detail page
1 participant