ddm.tsx 977 B

1234567891011121314151617181920212223242526272829303132
  1. import {useEffect} from 'react';
  2. import PageFiltersContainer from 'sentry/components/organizations/pageFilters/container';
  3. import SentryDocumentTitle from 'sentry/components/sentryDocumentTitle';
  4. import {t} from 'sentry/locale';
  5. import {trackAnalytics} from 'sentry/utils/analytics';
  6. import useOrganization from 'sentry/utils/useOrganization';
  7. import {DDMContextProvider} from 'sentry/views/ddm/context';
  8. import {DDMLayout} from 'sentry/views/ddm/layout';
  9. function DDM() {
  10. const organization = useOrganization();
  11. useEffect(() => {
  12. trackAnalytics('ddm.page-view', {
  13. organization,
  14. });
  15. // eslint-disable-next-line react-hooks/exhaustive-deps
  16. }, []);
  17. return (
  18. <SentryDocumentTitle title={t('Metrics')} orgSlug={organization.slug}>
  19. <PageFiltersContainer disablePersistence>
  20. <DDMContextProvider>
  21. <DDMLayout />
  22. </DDMContextProvider>
  23. </PageFiltersContainer>
  24. </SentryDocumentTitle>
  25. );
  26. }
  27. export default DDM;