Skip to content

Commit 66d531d

Browse files
authored
Revert "refactor: Remove the unnecessary logic (alibaba#1928)" (alibaba#1947)
This reverts commit 1f2c1b4.
1 parent 405f014 commit 66d531d

File tree

1 file changed

+1
-0
lines changed
  • packages/hooks/src/useUnmountedRef

1 file changed

+1
-0
lines changed

packages/hooks/src/useUnmountedRef/index.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { useEffect, useRef } from 'react';
33
const useUnmountedRef = () => {
44
const unmountedRef = useRef(false);
55
useEffect(() => {
6+
unmountedRef.current = false;
67
return () => {
78
unmountedRef.current = true;
89
};

0 commit comments

Comments
 (0)