import {Team} from 'sentry/types'; import getDisplayName from 'sentry/utils/getDisplayName'; import useTeams from 'sentry/utils/useTeams'; type InjectedTeamsProps = { teams?: Team[]; }; /** * Higher order component that provides a list of teams * * @deprecated Prefer `useTeams` or ``. */ const withTeams =

( WrappedComponent: React.ComponentType

) => { const WithTeams: React.FC< Omit & InjectedTeamsProps > = props => { const {teams} = useTeams(); return ; }; WithTeams.displayName = `withTeams(${getDisplayName(WrappedComponent)})`; return WithTeams; }; export default withTeams;