Skip to content

Latest commit

 

History

History
3 lines (3 loc) · 425 Bytes

README.md

File metadata and controls

3 lines (3 loc) · 425 Bytes

useWindowsize

CODE IN MASTER BRANCH

useWindowsize is a react js custom hook which can be used to get the current height and width of the window when vw & vh are not working. In certain conditions like absolutely positioned elements sometimes don't respond to viewport width & height, this hook is very much useful in those cases. It watches the height and width of the screen & updates the values in the state likewise.