mirror of
https://github.com/chansee97/nova-admin.git
synced 2025-05-30 06:39:16 +08:00
12 lines
245 B
TypeScript
12 lines
245 B
TypeScript
import { useBoolean } from './useBoolean';
|
|
|
|
export function useLoading(initValue = false) {
|
|
const { bool: loading, setTrue: startLoading, setFalse: endLoading } = useBoolean();
|
|
|
|
return {
|
|
loading,
|
|
startLoading,
|
|
endLoading,
|
|
};
|
|
}
|