re: Hide menu when scrolling in React.js VIEW POST

VIEW PARENT COMMENT VIEW FULL DISCUSSION
 

Storing the top as a state key is probably better, but to use React.createRef() is also an alternative to getElementById.

 

Thank you both! I've made some changes on the nav id and how I manage the CSS too.

code of conduct - report abuse