handleIntersectionChange method

void handleIntersectionChange(
  1. IntersectionObserverEntry entry
)

Implementation

void handleIntersectionChange(IntersectionObserverEntry entry) {
  dispatchEvent(IntersectionChangeEvent(entry.intersectionRatio));
  if (entry.intersectionRatio > 0) {
    handleAppear();
  } else {
    handleDisappear();
  }
}