scrollY property

int scrollY

The distance this window has been scrolled vertically.

Other resources

Implementation

int get scrollY => JS('bool', '("scrollY" in #)', this)
    ? JS('num', '#.scrollY', this).round()
    : document.documentElement.scrollTop;