UEA-Prodem
This commit is contained in:
+14
@@ -0,0 +1,14 @@
|
||||
import * as React from 'react';
|
||||
|
||||
let _isHydrated = false;
|
||||
|
||||
export function useIsHydrated() {
|
||||
const [isHydrated, setIsHydrated] = React.useState(_isHydrated);
|
||||
React.useEffect(() => {
|
||||
if (!_isHydrated) {
|
||||
_isHydrated = true;
|
||||
setIsHydrated(true);
|
||||
}
|
||||
}, []);
|
||||
return isHydrated;
|
||||
}
|
||||
Reference in New Issue
Block a user