javascript - Checking which span element is currently on the screen or the closest to it upwards -


this question has answer here:

i'm trying see span element visible on screen or closest upwards, i'm not sure how achieve this. page scroll able , spans visible. there selector visible on screen ?

guess, should compare window.scrolltop() , element scrolltop values. p.s. not forget include element height


Comments

Popular posts from this blog

php - Why I am getting the Error "Commands out of sync; you can't run this command now" -

linux - Does gcc have any options to add version info in ELF binary file? -

java - Are there any classes that implement javax.persistence.Parameter<T>? -