You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

storeHooks.ts 423B

1234567891011
  1. import { getOneNamespaceEffectsLoading } from '@/utils/storeUtil';
  2. import { useSelector } from 'umi';
  3. // Get the loading status of given effects under a certain namespace
  4. export const useOneNamespaceEffectsLoading = (
  5. namespace: string,
  6. effectNames: Array<string>,
  7. ) => {
  8. const effects = useSelector((state: any) => state.loading.effects);
  9. return getOneNamespaceEffectsLoading(namespace, effects, effectNames);
  10. };